/** The grammars this module parses, keyed by the id used in `tree-sitter-.wasm`. */ export type WasmLang = "python" | "ruby" | "rust"; /** A definition found by the walk — the same shape `symbols.ts` exports as `SymbolDef`. */ export interface WasmSymbolDef { readonly name: string; readonly kind: string; readonly scope: string; readonly line: number; } /** * Node kinds that open a scope (their `name` becomes the `scope` of everything inside), and the * kinds a `left` field must have to count as an assignment-style definition. ONE list for both * walkers — the napi one in `symbols.ts` and the one below — so they cannot drift apart. */ export declare const SCOPE_KINDS: readonly string[]; export declare const ID_KINDS: readonly string[]; /** * Load `lang`'s grammar once per process. Resolves to `null` on success, or the load error's own * text — the caller reports it verbatim as "not checked", never as a missing symbol. */ export declare function loadWasmGrammar(lang: WasmLang): Promise; /** Parse `code` and return its definitions. Rejects on a parse failure — never resolves []. */ export declare function wasmDefinedSymbols(code: string, lang: WasmLang): Promise; //# sourceMappingURL=tree-sitter-wasm.d.ts.map