|
1 | 1 | /* tslint:disable */ |
2 | 2 | /* eslint-disable */ |
3 | | -export function generate_root_with_proof(calldata_bytes: Uint8Array, tree_size: bigint): string; |
4 | | -export function verify_proof(root_hex: string, proof_hex: string[], mmr_size: bigint, leaf_position: bigint, calldata_bytes: Uint8Array): boolean; |
| 3 | +export function generate_root_with_proof(calldata_bytes: Uint8Array, tree_size: bigint): string |
| 4 | +export function verify_proof( |
| 5 | + root_hex: string, |
| 6 | + proof_hex: string[], |
| 7 | + mmr_size: bigint, |
| 8 | + leaf_position: bigint, |
| 9 | + calldata_bytes: Uint8Array, |
| 10 | +): boolean |
5 | 11 | export class KeccakMerge { |
6 | | - private constructor(); |
7 | | - free(): void; |
| 12 | + private constructor() |
| 13 | + free(): void |
8 | 14 | } |
9 | 15 |
|
10 | | -export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module; |
| 16 | +export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module |
11 | 17 |
|
12 | 18 | export interface InitOutput { |
13 | | - readonly memory: WebAssembly.Memory; |
14 | | - readonly __wbg_keccakmerge_free: (a: number, b: number) => void; |
15 | | - readonly generate_root_with_proof: (a: number, b: number, c: bigint) => [number, number, number, number]; |
16 | | - readonly verify_proof: (a: number, b: number, c: number, d: number, e: bigint, f: bigint, g: number, h: number) => [number, number, number]; |
17 | | - readonly __wbindgen_export_0: WebAssembly.Table; |
18 | | - readonly __wbindgen_malloc: (a: number, b: number) => number; |
19 | | - readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number; |
20 | | - readonly __externref_table_dealloc: (a: number) => void; |
21 | | - readonly __wbindgen_free: (a: number, b: number, c: number) => void; |
22 | | - readonly __externref_table_alloc: () => number; |
23 | | - readonly __wbindgen_start: () => void; |
| 19 | + readonly memory: WebAssembly.Memory |
| 20 | + readonly __wbg_keccakmerge_free: (a: number, b: number) => void |
| 21 | + readonly generate_root_with_proof: (a: number, b: number, c: bigint) => [number, number, number, number] |
| 22 | + readonly verify_proof: ( |
| 23 | + a: number, |
| 24 | + b: number, |
| 25 | + c: number, |
| 26 | + d: number, |
| 27 | + e: bigint, |
| 28 | + f: bigint, |
| 29 | + g: number, |
| 30 | + h: number, |
| 31 | + ) => [number, number, number] |
| 32 | + readonly __wbindgen_export_0: WebAssembly.Table |
| 33 | + readonly __wbindgen_malloc: (a: number, b: number) => number |
| 34 | + readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number |
| 35 | + readonly __externref_table_dealloc: (a: number) => void |
| 36 | + readonly __wbindgen_free: (a: number, b: number, c: number) => void |
| 37 | + readonly __externref_table_alloc: () => number |
| 38 | + readonly __wbindgen_start: () => void |
24 | 39 | } |
25 | 40 |
|
26 | | -export type SyncInitInput = BufferSource | WebAssembly.Module; |
| 41 | +export type SyncInitInput = BufferSource | WebAssembly.Module |
27 | 42 | /** |
28 | | -* Instantiates the given `module`, which can either be bytes or |
29 | | -* a precompiled `WebAssembly.Module`. |
30 | | -* |
31 | | -* @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated. |
32 | | -* |
33 | | -* @returns {InitOutput} |
34 | | -*/ |
35 | | -export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput; |
| 43 | + * Instantiates the given `module`, which can either be bytes or |
| 44 | + * a precompiled `WebAssembly.Module`. |
| 45 | + * |
| 46 | + * @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated. |
| 47 | + * |
| 48 | + * @returns {InitOutput} |
| 49 | + */ |
| 50 | +export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput |
36 | 51 |
|
37 | 52 | /** |
38 | | -* If `module_or_path` is {RequestInfo} or {URL}, makes a request and |
39 | | -* for everything else, calls `WebAssembly.instantiate` directly. |
40 | | -* |
41 | | -* @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated. |
42 | | -* |
43 | | -* @returns {Promise<InitOutput>} |
44 | | -*/ |
45 | | -export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>; |
| 53 | + * If `module_or_path` is {RequestInfo} or {URL}, makes a request and |
| 54 | + * for everything else, calls `WebAssembly.instantiate` directly. |
| 55 | + * |
| 56 | + * @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated. |
| 57 | + * |
| 58 | + * @returns {Promise<InitOutput>} |
| 59 | + */ |
| 60 | +export default function __wbg_init( |
| 61 | + module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>, |
| 62 | +): Promise<InitOutput> |
0 commit comments