@noir-lang/noir_wasm 1.0.0-beta.15-b34828f.nightly → 1.0.0-beta.15-1fce7ca.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/dist/node/index_bg.wasm +0 -0
- package/dist/node/main.js +29 -29
- package/dist/node/main.js.map +1 -1
- package/dist/types/build/cjs/index.d.ts +2 -2
- package/dist/types/build/esm/index.d.ts +16 -16
- package/dist/web/main.mjs +30 -30
- package/dist/web/main.mjs.map +1 -1
- package/package.json +2 -2
package/dist/node/index_bg.wasm
CHANGED
|
Binary file
|
package/dist/node/main.js
CHANGED
|
@@ -11436,17 +11436,19 @@ function takeFromExternrefTable0(idx) {
|
|
|
11436
11436
|
return value;
|
|
11437
11437
|
}
|
|
11438
11438
|
/**
|
|
11439
|
+
* This is a method that exposes the same API as `compile`
|
|
11440
|
+
* But uses the Context based APi internally
|
|
11439
11441
|
* @param {string} entry_point
|
|
11440
11442
|
* @param {DependencyGraph | null | undefined} dependency_graph
|
|
11441
11443
|
* @param {PathToFileSourceMap} file_source_map
|
|
11442
11444
|
* @returns {ProgramCompileResult}
|
|
11443
11445
|
*/
|
|
11444
|
-
module.exports.
|
|
11446
|
+
module.exports.compile_program_ = function(entry_point, dependency_graph, file_source_map) {
|
|
11445
11447
|
const ptr0 = passStringToWasm0(entry_point, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
11446
11448
|
const len0 = WASM_VECTOR_LEN;
|
|
11447
11449
|
_assertClass(file_source_map, PathToFileSourceMap);
|
|
11448
11450
|
var ptr1 = file_source_map.__destroy_into_raw();
|
|
11449
|
-
const ret = wasm.
|
|
11451
|
+
const ret = wasm.compile_program_(ptr0, len0, isLikeNone(dependency_graph) ? 0 : addToExternrefTable0(dependency_graph), ptr1);
|
|
11450
11452
|
if (ret[2]) {
|
|
11451
11453
|
throw takeFromExternrefTable0(ret[1]);
|
|
11452
11454
|
}
|
|
@@ -11454,17 +11456,19 @@ module.exports.compile_program = function(entry_point, dependency_graph, file_so
|
|
|
11454
11456
|
};
|
|
11455
11457
|
|
|
11456
11458
|
/**
|
|
11459
|
+
* This is a method that exposes the same API as `compile`
|
|
11460
|
+
* But uses the Context based APi internally
|
|
11457
11461
|
* @param {string} entry_point
|
|
11458
11462
|
* @param {DependencyGraph | null | undefined} dependency_graph
|
|
11459
11463
|
* @param {PathToFileSourceMap} file_source_map
|
|
11460
11464
|
* @returns {ContractCompileResult}
|
|
11461
11465
|
*/
|
|
11462
|
-
module.exports.
|
|
11466
|
+
module.exports.compile_contract_ = function(entry_point, dependency_graph, file_source_map) {
|
|
11463
11467
|
const ptr0 = passStringToWasm0(entry_point, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
11464
11468
|
const len0 = WASM_VECTOR_LEN;
|
|
11465
11469
|
_assertClass(file_source_map, PathToFileSourceMap);
|
|
11466
11470
|
var ptr1 = file_source_map.__destroy_into_raw();
|
|
11467
|
-
const ret = wasm.
|
|
11471
|
+
const ret = wasm.compile_contract_(ptr0, len0, isLikeNone(dependency_graph) ? 0 : addToExternrefTable0(dependency_graph), ptr1);
|
|
11468
11472
|
if (ret[2]) {
|
|
11469
11473
|
throw takeFromExternrefTable0(ret[1]);
|
|
11470
11474
|
}
|
|
@@ -11472,36 +11476,17 @@ module.exports.compile_contract = function(entry_point, dependency_graph, file_s
|
|
|
11472
11476
|
};
|
|
11473
11477
|
|
|
11474
11478
|
/**
|
|
11475
|
-
* @param {string} level
|
|
11476
|
-
*/
|
|
11477
|
-
module.exports.init_log_level = function(level) {
|
|
11478
|
-
const ptr0 = passStringToWasm0(level, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
11479
|
-
const len0 = WASM_VECTOR_LEN;
|
|
11480
|
-
wasm.init_log_level(ptr0, len0);
|
|
11481
|
-
};
|
|
11482
|
-
|
|
11483
|
-
/**
|
|
11484
|
-
* @returns {any}
|
|
11485
|
-
*/
|
|
11486
|
-
module.exports.build_info = function() {
|
|
11487
|
-
const ret = wasm.build_info();
|
|
11488
|
-
return ret;
|
|
11489
|
-
};
|
|
11490
|
-
|
|
11491
|
-
/**
|
|
11492
|
-
* This is a method that exposes the same API as `compile`
|
|
11493
|
-
* But uses the Context based APi internally
|
|
11494
11479
|
* @param {string} entry_point
|
|
11495
11480
|
* @param {DependencyGraph | null | undefined} dependency_graph
|
|
11496
11481
|
* @param {PathToFileSourceMap} file_source_map
|
|
11497
11482
|
* @returns {ProgramCompileResult}
|
|
11498
11483
|
*/
|
|
11499
|
-
module.exports.
|
|
11484
|
+
module.exports.compile_program = function(entry_point, dependency_graph, file_source_map) {
|
|
11500
11485
|
const ptr0 = passStringToWasm0(entry_point, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
11501
11486
|
const len0 = WASM_VECTOR_LEN;
|
|
11502
11487
|
_assertClass(file_source_map, PathToFileSourceMap);
|
|
11503
11488
|
var ptr1 = file_source_map.__destroy_into_raw();
|
|
11504
|
-
const ret = wasm.
|
|
11489
|
+
const ret = wasm.compile_program(ptr0, len0, isLikeNone(dependency_graph) ? 0 : addToExternrefTable0(dependency_graph), ptr1);
|
|
11505
11490
|
if (ret[2]) {
|
|
11506
11491
|
throw takeFromExternrefTable0(ret[1]);
|
|
11507
11492
|
}
|
|
@@ -11509,25 +11494,40 @@ module.exports.compile_program_ = function(entry_point, dependency_graph, file_s
|
|
|
11509
11494
|
};
|
|
11510
11495
|
|
|
11511
11496
|
/**
|
|
11512
|
-
* This is a method that exposes the same API as `compile`
|
|
11513
|
-
* But uses the Context based APi internally
|
|
11514
11497
|
* @param {string} entry_point
|
|
11515
11498
|
* @param {DependencyGraph | null | undefined} dependency_graph
|
|
11516
11499
|
* @param {PathToFileSourceMap} file_source_map
|
|
11517
11500
|
* @returns {ContractCompileResult}
|
|
11518
11501
|
*/
|
|
11519
|
-
module.exports.
|
|
11502
|
+
module.exports.compile_contract = function(entry_point, dependency_graph, file_source_map) {
|
|
11520
11503
|
const ptr0 = passStringToWasm0(entry_point, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
11521
11504
|
const len0 = WASM_VECTOR_LEN;
|
|
11522
11505
|
_assertClass(file_source_map, PathToFileSourceMap);
|
|
11523
11506
|
var ptr1 = file_source_map.__destroy_into_raw();
|
|
11524
|
-
const ret = wasm.
|
|
11507
|
+
const ret = wasm.compile_contract(ptr0, len0, isLikeNone(dependency_graph) ? 0 : addToExternrefTable0(dependency_graph), ptr1);
|
|
11525
11508
|
if (ret[2]) {
|
|
11526
11509
|
throw takeFromExternrefTable0(ret[1]);
|
|
11527
11510
|
}
|
|
11528
11511
|
return takeFromExternrefTable0(ret[0]);
|
|
11529
11512
|
};
|
|
11530
11513
|
|
|
11514
|
+
/**
|
|
11515
|
+
* @param {string} level
|
|
11516
|
+
*/
|
|
11517
|
+
module.exports.init_log_level = function(level) {
|
|
11518
|
+
const ptr0 = passStringToWasm0(level, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
11519
|
+
const len0 = WASM_VECTOR_LEN;
|
|
11520
|
+
wasm.init_log_level(ptr0, len0);
|
|
11521
|
+
};
|
|
11522
|
+
|
|
11523
|
+
/**
|
|
11524
|
+
* @returns {any}
|
|
11525
|
+
*/
|
|
11526
|
+
module.exports.build_info = function() {
|
|
11527
|
+
const ret = wasm.build_info();
|
|
11528
|
+
return ret;
|
|
11529
|
+
};
|
|
11530
|
+
|
|
11531
11531
|
const CompilerContextFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
11532
11532
|
? { register: () => {}, unregister: () => {} }
|
|
11533
11533
|
: new FinalizationRegistry(ptr => wasm.__wbg_compilercontext_free(ptr >>> 0, 1));
|