@noir-lang/noir_wasm 0.22.0-698d5fd.nightly → 0.22.0-d025731.nightly
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/nodejs/noir_wasm.d.ts +2 -12
- package/nodejs/noir_wasm.js +21 -52
- package/nodejs/noir_wasm_bg.wasm +0 -0
- package/nodejs/noir_wasm_bg.wasm.d.ts +0 -2
- package/package.json +1 -1
- package/web/noir_wasm.d.ts +2 -14
- package/web/noir_wasm.js +18 -51
- package/web/noir_wasm_bg.wasm +0 -0
- package/web/noir_wasm_bg.wasm.d.ts +0 -2
package/nodejs/noir_wasm.d.ts
CHANGED
|
@@ -1,16 +1,6 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
/**
|
|
4
|
-
* @param {Uint8Array} bytes
|
|
5
|
-
* @returns {any}
|
|
6
|
-
*/
|
|
7
|
-
export function acir_read_bytes(bytes: Uint8Array): any;
|
|
8
|
-
/**
|
|
9
|
-
* @param {any} acir
|
|
10
|
-
* @returns {Uint8Array}
|
|
11
|
-
*/
|
|
12
|
-
export function acir_write_bytes(acir: any): Uint8Array;
|
|
13
|
-
/**
|
|
14
4
|
* This is a method that exposes the same API as `compile`
|
|
15
5
|
* But uses the Context based APi internally
|
|
16
6
|
* @param {string} entry_point
|
|
@@ -21,9 +11,9 @@ export function acir_write_bytes(acir: any): Uint8Array;
|
|
|
21
11
|
*/
|
|
22
12
|
export function compile_(entry_point: string, contracts: boolean | undefined, dependency_graph: DependencyGraph | undefined, file_source_map: PathToFileSourceMap): CompileResult;
|
|
23
13
|
/**
|
|
24
|
-
* @param {string}
|
|
14
|
+
* @param {string} filter
|
|
25
15
|
*/
|
|
26
|
-
export function init_log_level(
|
|
16
|
+
export function init_log_level(filter: string): void;
|
|
27
17
|
/**
|
|
28
18
|
* @returns {any}
|
|
29
19
|
*/
|
package/nodejs/noir_wasm.js
CHANGED
|
@@ -183,45 +183,6 @@ function debugString(val) {
|
|
|
183
183
|
return className;
|
|
184
184
|
}
|
|
185
185
|
|
|
186
|
-
function passArray8ToWasm0(arg, malloc) {
|
|
187
|
-
const ptr = malloc(arg.length * 1) >>> 0;
|
|
188
|
-
getUint8Memory0().set(arg, ptr / 1);
|
|
189
|
-
WASM_VECTOR_LEN = arg.length;
|
|
190
|
-
return ptr;
|
|
191
|
-
}
|
|
192
|
-
/**
|
|
193
|
-
* @param {Uint8Array} bytes
|
|
194
|
-
* @returns {any}
|
|
195
|
-
*/
|
|
196
|
-
module.exports.acir_read_bytes = function(bytes) {
|
|
197
|
-
const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_export_0);
|
|
198
|
-
const len0 = WASM_VECTOR_LEN;
|
|
199
|
-
const ret = wasm.acir_read_bytes(ptr0, len0);
|
|
200
|
-
return takeObject(ret);
|
|
201
|
-
};
|
|
202
|
-
|
|
203
|
-
function getArrayU8FromWasm0(ptr, len) {
|
|
204
|
-
ptr = ptr >>> 0;
|
|
205
|
-
return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);
|
|
206
|
-
}
|
|
207
|
-
/**
|
|
208
|
-
* @param {any} acir
|
|
209
|
-
* @returns {Uint8Array}
|
|
210
|
-
*/
|
|
211
|
-
module.exports.acir_write_bytes = function(acir) {
|
|
212
|
-
try {
|
|
213
|
-
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
214
|
-
wasm.acir_write_bytes(retptr, addHeapObject(acir));
|
|
215
|
-
var r0 = getInt32Memory0()[retptr / 4 + 0];
|
|
216
|
-
var r1 = getInt32Memory0()[retptr / 4 + 1];
|
|
217
|
-
var v1 = getArrayU8FromWasm0(r0, r1).slice();
|
|
218
|
-
wasm.__wbindgen_export_2(r0, r1 * 1);
|
|
219
|
-
return v1;
|
|
220
|
-
} finally {
|
|
221
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
222
|
-
}
|
|
223
|
-
};
|
|
224
|
-
|
|
225
186
|
function _assertClass(instance, klass) {
|
|
226
187
|
if (!(instance instanceof klass)) {
|
|
227
188
|
throw new Error(`expected instance of ${klass.name}`);
|
|
@@ -258,10 +219,10 @@ module.exports.compile_ = function(entry_point, contracts, dependency_graph, fil
|
|
|
258
219
|
};
|
|
259
220
|
|
|
260
221
|
/**
|
|
261
|
-
* @param {string}
|
|
222
|
+
* @param {string} filter
|
|
262
223
|
*/
|
|
263
|
-
module.exports.init_log_level = function(
|
|
264
|
-
const ptr0 = passStringToWasm0(
|
|
224
|
+
module.exports.init_log_level = function(filter) {
|
|
225
|
+
const ptr0 = passStringToWasm0(filter, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
265
226
|
const len0 = WASM_VECTOR_LEN;
|
|
266
227
|
wasm.init_log_level(ptr0, len0);
|
|
267
228
|
};
|
|
@@ -496,19 +457,14 @@ module.exports.__wbg_constructor_a29cdb41a75eb0e8 = function(arg0) {
|
|
|
496
457
|
return addHeapObject(ret);
|
|
497
458
|
};
|
|
498
459
|
|
|
499
|
-
module.exports.__wbindgen_is_undefined = function(arg0) {
|
|
500
|
-
const ret = getObject(arg0) === undefined;
|
|
501
|
-
return ret;
|
|
502
|
-
};
|
|
503
|
-
|
|
504
460
|
module.exports.__wbg_constructor_a3b5b211c5053ce8 = function() {
|
|
505
461
|
const ret = new Object();
|
|
506
462
|
return addHeapObject(ret);
|
|
507
463
|
};
|
|
508
464
|
|
|
509
|
-
module.exports.
|
|
510
|
-
const ret =
|
|
511
|
-
return
|
|
465
|
+
module.exports.__wbindgen_is_undefined = function(arg0) {
|
|
466
|
+
const ret = getObject(arg0) === undefined;
|
|
467
|
+
return ret;
|
|
512
468
|
};
|
|
513
469
|
|
|
514
470
|
module.exports.__wbg_new_abda76e883ba8a5f = function() {
|
|
@@ -536,6 +492,15 @@ module.exports.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {
|
|
|
536
492
|
}
|
|
537
493
|
};
|
|
538
494
|
|
|
495
|
+
module.exports.__wbindgen_string_new = function(arg0, arg1) {
|
|
496
|
+
const ret = getStringFromWasm0(arg0, arg1);
|
|
497
|
+
return addHeapObject(ret);
|
|
498
|
+
};
|
|
499
|
+
|
|
500
|
+
module.exports.__wbg_debug_e3f6a1578e6d45ca = function(arg0) {
|
|
501
|
+
console.debug(getObject(arg0));
|
|
502
|
+
};
|
|
503
|
+
|
|
539
504
|
module.exports.__wbg_debug_efabe4eb183aa5d4 = function(arg0, arg1, arg2, arg3) {
|
|
540
505
|
console.debug(getObject(arg0), getObject(arg1), getObject(arg2), getObject(arg3));
|
|
541
506
|
};
|
|
@@ -548,12 +513,16 @@ module.exports.__wbg_error_50f42b952a595a23 = function(arg0, arg1, arg2, arg3) {
|
|
|
548
513
|
console.error(getObject(arg0), getObject(arg1), getObject(arg2), getObject(arg3));
|
|
549
514
|
};
|
|
550
515
|
|
|
516
|
+
module.exports.__wbg_info_05db236d79f1b785 = function(arg0) {
|
|
517
|
+
console.info(getObject(arg0));
|
|
518
|
+
};
|
|
519
|
+
|
|
551
520
|
module.exports.__wbg_info_24d8f53d98f12b95 = function(arg0, arg1, arg2, arg3) {
|
|
552
521
|
console.info(getObject(arg0), getObject(arg1), getObject(arg2), getObject(arg3));
|
|
553
522
|
};
|
|
554
523
|
|
|
555
|
-
module.exports.
|
|
556
|
-
console.
|
|
524
|
+
module.exports.__wbg_warn_9bdd743e9f5fe1e0 = function(arg0) {
|
|
525
|
+
console.warn(getObject(arg0));
|
|
557
526
|
};
|
|
558
527
|
|
|
559
528
|
module.exports.__wbg_warn_8342bfbc6028193a = function(arg0, arg1, arg2, arg3) {
|
package/nodejs/noir_wasm_bg.wasm
CHANGED
|
Binary file
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
export const memory: WebAssembly.Memory;
|
|
4
|
-
export function acir_read_bytes(a: number, b: number): number;
|
|
5
|
-
export function acir_write_bytes(a: number, b: number): void;
|
|
6
4
|
export function __wbg_compilercontext_free(a: number): void;
|
|
7
5
|
export function __wbg_crateid_free(a: number): void;
|
|
8
6
|
export function compilercontext_new(a: number): number;
|
package/package.json
CHANGED
package/web/noir_wasm.d.ts
CHANGED
|
@@ -1,16 +1,6 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
/**
|
|
4
|
-
* @param {Uint8Array} bytes
|
|
5
|
-
* @returns {any}
|
|
6
|
-
*/
|
|
7
|
-
export function acir_read_bytes(bytes: Uint8Array): any;
|
|
8
|
-
/**
|
|
9
|
-
* @param {any} acir
|
|
10
|
-
* @returns {Uint8Array}
|
|
11
|
-
*/
|
|
12
|
-
export function acir_write_bytes(acir: any): Uint8Array;
|
|
13
|
-
/**
|
|
14
4
|
* This is a method that exposes the same API as `compile`
|
|
15
5
|
* But uses the Context based APi internally
|
|
16
6
|
* @param {string} entry_point
|
|
@@ -21,9 +11,9 @@ export function acir_write_bytes(acir: any): Uint8Array;
|
|
|
21
11
|
*/
|
|
22
12
|
export function compile_(entry_point: string, contracts: boolean | undefined, dependency_graph: DependencyGraph | undefined, file_source_map: PathToFileSourceMap): CompileResult;
|
|
23
13
|
/**
|
|
24
|
-
* @param {string}
|
|
14
|
+
* @param {string} filter
|
|
25
15
|
*/
|
|
26
|
-
export function init_log_level(
|
|
16
|
+
export function init_log_level(filter: string): void;
|
|
27
17
|
/**
|
|
28
18
|
* @returns {any}
|
|
29
19
|
*/
|
|
@@ -152,8 +142,6 @@ export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembl
|
|
|
152
142
|
|
|
153
143
|
export interface InitOutput {
|
|
154
144
|
readonly memory: WebAssembly.Memory;
|
|
155
|
-
readonly acir_read_bytes: (a: number, b: number) => number;
|
|
156
|
-
readonly acir_write_bytes: (a: number, b: number) => void;
|
|
157
145
|
readonly __wbg_compilercontext_free: (a: number) => void;
|
|
158
146
|
readonly __wbg_crateid_free: (a: number) => void;
|
|
159
147
|
readonly compilercontext_new: (a: number) => number;
|
package/web/noir_wasm.js
CHANGED
|
@@ -180,45 +180,6 @@ function debugString(val) {
|
|
|
180
180
|
return className;
|
|
181
181
|
}
|
|
182
182
|
|
|
183
|
-
function passArray8ToWasm0(arg, malloc) {
|
|
184
|
-
const ptr = malloc(arg.length * 1) >>> 0;
|
|
185
|
-
getUint8Memory0().set(arg, ptr / 1);
|
|
186
|
-
WASM_VECTOR_LEN = arg.length;
|
|
187
|
-
return ptr;
|
|
188
|
-
}
|
|
189
|
-
/**
|
|
190
|
-
* @param {Uint8Array} bytes
|
|
191
|
-
* @returns {any}
|
|
192
|
-
*/
|
|
193
|
-
export function acir_read_bytes(bytes) {
|
|
194
|
-
const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_export_0);
|
|
195
|
-
const len0 = WASM_VECTOR_LEN;
|
|
196
|
-
const ret = wasm.acir_read_bytes(ptr0, len0);
|
|
197
|
-
return takeObject(ret);
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
function getArrayU8FromWasm0(ptr, len) {
|
|
201
|
-
ptr = ptr >>> 0;
|
|
202
|
-
return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);
|
|
203
|
-
}
|
|
204
|
-
/**
|
|
205
|
-
* @param {any} acir
|
|
206
|
-
* @returns {Uint8Array}
|
|
207
|
-
*/
|
|
208
|
-
export function acir_write_bytes(acir) {
|
|
209
|
-
try {
|
|
210
|
-
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
211
|
-
wasm.acir_write_bytes(retptr, addHeapObject(acir));
|
|
212
|
-
var r0 = getInt32Memory0()[retptr / 4 + 0];
|
|
213
|
-
var r1 = getInt32Memory0()[retptr / 4 + 1];
|
|
214
|
-
var v1 = getArrayU8FromWasm0(r0, r1).slice();
|
|
215
|
-
wasm.__wbindgen_export_2(r0, r1 * 1);
|
|
216
|
-
return v1;
|
|
217
|
-
} finally {
|
|
218
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
219
|
-
}
|
|
220
|
-
}
|
|
221
|
-
|
|
222
183
|
function _assertClass(instance, klass) {
|
|
223
184
|
if (!(instance instanceof klass)) {
|
|
224
185
|
throw new Error(`expected instance of ${klass.name}`);
|
|
@@ -255,10 +216,10 @@ export function compile_(entry_point, contracts, dependency_graph, file_source_m
|
|
|
255
216
|
}
|
|
256
217
|
|
|
257
218
|
/**
|
|
258
|
-
* @param {string}
|
|
219
|
+
* @param {string} filter
|
|
259
220
|
*/
|
|
260
|
-
export function init_log_level(
|
|
261
|
-
const ptr0 = passStringToWasm0(
|
|
221
|
+
export function init_log_level(filter) {
|
|
222
|
+
const ptr0 = passStringToWasm0(filter, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
|
|
262
223
|
const len0 = WASM_VECTOR_LEN;
|
|
263
224
|
wasm.init_log_level(ptr0, len0);
|
|
264
225
|
}
|
|
@@ -522,17 +483,13 @@ function __wbg_get_imports() {
|
|
|
522
483
|
const ret = new Error(takeObject(arg0));
|
|
523
484
|
return addHeapObject(ret);
|
|
524
485
|
};
|
|
525
|
-
imports.wbg.__wbindgen_is_undefined = function(arg0) {
|
|
526
|
-
const ret = getObject(arg0) === undefined;
|
|
527
|
-
return ret;
|
|
528
|
-
};
|
|
529
486
|
imports.wbg.__wbg_constructor_a3b5b211c5053ce8 = function() {
|
|
530
487
|
const ret = new Object();
|
|
531
488
|
return addHeapObject(ret);
|
|
532
489
|
};
|
|
533
|
-
imports.wbg.
|
|
534
|
-
const ret =
|
|
535
|
-
return
|
|
490
|
+
imports.wbg.__wbindgen_is_undefined = function(arg0) {
|
|
491
|
+
const ret = getObject(arg0) === undefined;
|
|
492
|
+
return ret;
|
|
536
493
|
};
|
|
537
494
|
imports.wbg.__wbg_new_abda76e883ba8a5f = function() {
|
|
538
495
|
const ret = new Error();
|
|
@@ -556,6 +513,13 @@ function __wbg_get_imports() {
|
|
|
556
513
|
wasm.__wbindgen_export_2(deferred0_0, deferred0_1);
|
|
557
514
|
}
|
|
558
515
|
};
|
|
516
|
+
imports.wbg.__wbindgen_string_new = function(arg0, arg1) {
|
|
517
|
+
const ret = getStringFromWasm0(arg0, arg1);
|
|
518
|
+
return addHeapObject(ret);
|
|
519
|
+
};
|
|
520
|
+
imports.wbg.__wbg_debug_e3f6a1578e6d45ca = function(arg0) {
|
|
521
|
+
console.debug(getObject(arg0));
|
|
522
|
+
};
|
|
559
523
|
imports.wbg.__wbg_debug_efabe4eb183aa5d4 = function(arg0, arg1, arg2, arg3) {
|
|
560
524
|
console.debug(getObject(arg0), getObject(arg1), getObject(arg2), getObject(arg3));
|
|
561
525
|
};
|
|
@@ -565,11 +529,14 @@ function __wbg_get_imports() {
|
|
|
565
529
|
imports.wbg.__wbg_error_50f42b952a595a23 = function(arg0, arg1, arg2, arg3) {
|
|
566
530
|
console.error(getObject(arg0), getObject(arg1), getObject(arg2), getObject(arg3));
|
|
567
531
|
};
|
|
532
|
+
imports.wbg.__wbg_info_05db236d79f1b785 = function(arg0) {
|
|
533
|
+
console.info(getObject(arg0));
|
|
534
|
+
};
|
|
568
535
|
imports.wbg.__wbg_info_24d8f53d98f12b95 = function(arg0, arg1, arg2, arg3) {
|
|
569
536
|
console.info(getObject(arg0), getObject(arg1), getObject(arg2), getObject(arg3));
|
|
570
537
|
};
|
|
571
|
-
imports.wbg.
|
|
572
|
-
console.
|
|
538
|
+
imports.wbg.__wbg_warn_9bdd743e9f5fe1e0 = function(arg0) {
|
|
539
|
+
console.warn(getObject(arg0));
|
|
573
540
|
};
|
|
574
541
|
imports.wbg.__wbg_warn_8342bfbc6028193a = function(arg0, arg1, arg2, arg3) {
|
|
575
542
|
console.warn(getObject(arg0), getObject(arg1), getObject(arg2), getObject(arg3));
|
package/web/noir_wasm_bg.wasm
CHANGED
|
Binary file
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
export const memory: WebAssembly.Memory;
|
|
4
|
-
export function acir_read_bytes(a: number, b: number): number;
|
|
5
|
-
export function acir_write_bytes(a: number, b: number): void;
|
|
6
4
|
export function __wbg_compilercontext_free(a: number): void;
|
|
7
5
|
export function __wbg_crateid_free(a: number): void;
|
|
8
6
|
export function compilercontext_new(a: number): number;
|