import * as babel from '@babel/types';
import * as acorn from 'acorn';
import * as tinyest from 'tinyest';

type JsNode = babel.Node | acorn.AnyNode;
type TranspilationResult = {
    params: tinyest.FuncParameter[];
    body: tinyest.Block;
    /**
     * All identifiers found in the function code that are not declared in the
     * function itself, or in the block that is accessing that identifier.
     */
    externalNames: string[];
};
declare function transpileFn(rootNode: JsNode): TranspilationResult;
declare function transpileNode(node: JsNode): tinyest.AnyNode;

export { transpileFn, transpileNode };
