nanowasm/private_include/nw/search.h

30 lines
695 B
C

/*
* nanowasm, a tiny WebAssembly/Wasm interpreter
* Copyright (C) 2023-2024 Xavier Del Campo Romero
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
#ifndef SEARCH_H
#define SEARCH_H
#include <nanowasm/nw.h>
#include <nw/types.h>
#include <stdio.h>
struct search_fn
{
long start;
bool returns;
varuint32 index;
};
int search_exported_fn(const char *fn, const struct nw_mod *m, FILE *f,
struct search_fn *out);
int search_fn(varuint32 index, const struct nw_mod *m, FILE *f,
struct search_fn *out);
#endif