@noir-lang/noir_wasm 0.38.0 → 0.39.0-45eb756.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.
@@ -3,7 +3,7 @@
3
3
  "collaborators": [
4
4
  "The Noir Team <team@noir-lang.org>"
5
5
  ],
6
- "version": "0.38.0",
6
+ "version": "0.39.0",
7
7
  "license": "MIT OR Apache-2.0",
8
8
  "files": [
9
9
  "index_bg.wasm",
@@ -3,7 +3,7 @@
3
3
  "collaborators": [
4
4
  "The Noir Team <team@noir-lang.org>"
5
5
  ],
6
- "version": "0.38.0",
6
+ "version": "0.39.0",
7
7
  "license": "MIT OR Apache-2.0",
8
8
  "files": [
9
9
  "index_bg.wasm",
Binary file
package/dist/node/main.js CHANGED
@@ -191,22 +191,6 @@ function debugString(val) {
191
191
  // TODO we could test for more things here, like `Set`s and `Map`s.
192
192
  return className;
193
193
  }
194
- /**
195
- * @param {string} level
196
- */
197
- module.exports.init_log_level = function(level) {
198
- const ptr0 = passStringToWasm0(level, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
199
- const len0 = WASM_VECTOR_LEN;
200
- wasm.init_log_level(ptr0, len0);
201
- };
202
-
203
- /**
204
- * @returns {any}
205
- */
206
- module.exports.build_info = function() {
207
- const ret = wasm.build_info();
208
- return takeObject(ret);
209
- };
210
194
 
211
195
  function _assertClass(instance, klass) {
212
196
  if (!(instance instanceof klass)) {
@@ -215,19 +199,21 @@ function _assertClass(instance, klass) {
215
199
  return instance.ptr;
216
200
  }
217
201
  /**
202
+ * This is a method that exposes the same API as `compile`
203
+ * But uses the Context based APi internally
218
204
  * @param {string} entry_point
219
205
  * @param {DependencyGraph | undefined} dependency_graph
220
206
  * @param {PathToFileSourceMap} file_source_map
221
207
  * @returns {ProgramCompileResult}
222
208
  */
223
- module.exports.compile_program = function(entry_point, dependency_graph, file_source_map) {
209
+ module.exports.compile_program_ = function(entry_point, dependency_graph, file_source_map) {
224
210
  try {
225
211
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
226
212
  const ptr0 = passStringToWasm0(entry_point, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
227
213
  const len0 = WASM_VECTOR_LEN;
228
214
  _assertClass(file_source_map, PathToFileSourceMap);
229
215
  var ptr1 = file_source_map.__destroy_into_raw();
230
- wasm.compile_program(retptr, ptr0, len0, isLikeNone(dependency_graph) ? 0 : addHeapObject(dependency_graph), ptr1);
216
+ wasm.compile_program_(retptr, ptr0, len0, isLikeNone(dependency_graph) ? 0 : addHeapObject(dependency_graph), ptr1);
231
217
  var r0 = getInt32Memory0()[retptr / 4 + 0];
232
218
  var r1 = getInt32Memory0()[retptr / 4 + 1];
233
219
  var r2 = getInt32Memory0()[retptr / 4 + 2];
@@ -241,19 +227,21 @@ module.exports.compile_program = function(entry_point, dependency_graph, file_so
241
227
  };
242
228
 
243
229
  /**
230
+ * This is a method that exposes the same API as `compile`
231
+ * But uses the Context based APi internally
244
232
  * @param {string} entry_point
245
233
  * @param {DependencyGraph | undefined} dependency_graph
246
234
  * @param {PathToFileSourceMap} file_source_map
247
235
  * @returns {ContractCompileResult}
248
236
  */
249
- module.exports.compile_contract = function(entry_point, dependency_graph, file_source_map) {
237
+ module.exports.compile_contract_ = function(entry_point, dependency_graph, file_source_map) {
250
238
  try {
251
239
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
252
240
  const ptr0 = passStringToWasm0(entry_point, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
253
241
  const len0 = WASM_VECTOR_LEN;
254
242
  _assertClass(file_source_map, PathToFileSourceMap);
255
243
  var ptr1 = file_source_map.__destroy_into_raw();
256
- wasm.compile_contract(retptr, ptr0, len0, isLikeNone(dependency_graph) ? 0 : addHeapObject(dependency_graph), ptr1);
244
+ wasm.compile_contract_(retptr, ptr0, len0, isLikeNone(dependency_graph) ? 0 : addHeapObject(dependency_graph), ptr1);
257
245
  var r0 = getInt32Memory0()[retptr / 4 + 0];
258
246
  var r1 = getInt32Memory0()[retptr / 4 + 1];
259
247
  var r2 = getInt32Memory0()[retptr / 4 + 2];
@@ -267,21 +255,36 @@ module.exports.compile_contract = function(entry_point, dependency_graph, file_s
267
255
  };
268
256
 
269
257
  /**
270
- * This is a method that exposes the same API as `compile`
271
- * But uses the Context based APi internally
258
+ * @param {string} level
259
+ */
260
+ module.exports.init_log_level = function(level) {
261
+ const ptr0 = passStringToWasm0(level, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
262
+ const len0 = WASM_VECTOR_LEN;
263
+ wasm.init_log_level(ptr0, len0);
264
+ };
265
+
266
+ /**
267
+ * @returns {any}
268
+ */
269
+ module.exports.build_info = function() {
270
+ const ret = wasm.build_info();
271
+ return takeObject(ret);
272
+ };
273
+
274
+ /**
272
275
  * @param {string} entry_point
273
276
  * @param {DependencyGraph | undefined} dependency_graph
274
277
  * @param {PathToFileSourceMap} file_source_map
275
278
  * @returns {ProgramCompileResult}
276
279
  */
277
- module.exports.compile_program_ = function(entry_point, dependency_graph, file_source_map) {
280
+ module.exports.compile_program = function(entry_point, dependency_graph, file_source_map) {
278
281
  try {
279
282
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
280
283
  const ptr0 = passStringToWasm0(entry_point, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
281
284
  const len0 = WASM_VECTOR_LEN;
282
285
  _assertClass(file_source_map, PathToFileSourceMap);
283
286
  var ptr1 = file_source_map.__destroy_into_raw();
284
- wasm.compile_program_(retptr, ptr0, len0, isLikeNone(dependency_graph) ? 0 : addHeapObject(dependency_graph), ptr1);
287
+ wasm.compile_program(retptr, ptr0, len0, isLikeNone(dependency_graph) ? 0 : addHeapObject(dependency_graph), ptr1);
285
288
  var r0 = getInt32Memory0()[retptr / 4 + 0];
286
289
  var r1 = getInt32Memory0()[retptr / 4 + 1];
287
290
  var r2 = getInt32Memory0()[retptr / 4 + 2];
@@ -295,21 +298,19 @@ module.exports.compile_program_ = function(entry_point, dependency_graph, file_s
295
298
  };
296
299
 
297
300
  /**
298
- * This is a method that exposes the same API as `compile`
299
- * But uses the Context based APi internally
300
301
  * @param {string} entry_point
301
302
  * @param {DependencyGraph | undefined} dependency_graph
302
303
  * @param {PathToFileSourceMap} file_source_map
303
304
  * @returns {ContractCompileResult}
304
305
  */
305
- module.exports.compile_contract_ = function(entry_point, dependency_graph, file_source_map) {
306
+ module.exports.compile_contract = function(entry_point, dependency_graph, file_source_map) {
306
307
  try {
307
308
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
308
309
  const ptr0 = passStringToWasm0(entry_point, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
309
310
  const len0 = WASM_VECTOR_LEN;
310
311
  _assertClass(file_source_map, PathToFileSourceMap);
311
312
  var ptr1 = file_source_map.__destroy_into_raw();
312
- wasm.compile_contract_(retptr, ptr0, len0, isLikeNone(dependency_graph) ? 0 : addHeapObject(dependency_graph), ptr1);
313
+ wasm.compile_contract(retptr, ptr0, len0, isLikeNone(dependency_graph) ? 0 : addHeapObject(dependency_graph), ptr1);
313
314
  var r0 = getInt32Memory0()[retptr / 4 + 0];
314
315
  var r1 = getInt32Memory0()[retptr / 4 + 1];
315
316
  var r2 = getInt32Memory0()[retptr / 4 + 2];
@@ -522,7 +523,7 @@ module.exports.__wbindgen_object_drop_ref = function(arg0) {
522
523
  takeObject(arg0);
523
524
  };
524
525
 
525
- module.exports.__wbg_constructor_4b094d25f96a28ea = function(arg0) {
526
+ module.exports.__wbg_constructor_2015eb4f96aa5c57 = function(arg0) {
526
527
  const ret = new Error(takeObject(arg0));
527
528
  return addHeapObject(ret);
528
529
  };
@@ -532,7 +533,7 @@ module.exports.__wbindgen_is_undefined = function(arg0) {
532
533
  return ret;
533
534
  };
534
535
 
535
- module.exports.__wbg_constructor_df95a026f19d407a = function() {
536
+ module.exports.__wbg_constructor_375b49c7a073f460 = function() {
536
537
  const ret = new Object();
537
538
  return addHeapObject(ret);
538
539
  };