/**
 * `entryPointIndex` is the index in the `statements` array of the `main` function
 *   `entryPointIndex` is set to -1 for modules
 *   If a `main` function isn't found for a non-module script an error is thrown
 * @typedef {{
 *   purpose: Word
 *   name:    Word
 *   statements: Statement[]
 *   entryPointIndex: number
 * }} ParsedScript
 */
/**
 * @param {string | Source} src
 * @param {ErrorCollector | undefined} errorCollector
 * @returns {ParsedScript}
 */
export function parseScript(src: string | Source, errorCollector?: ErrorCollector | undefined): ParsedScript;
/**
 * @param {string | Source} rawSrc
 * @returns {Source}
 */
export function createSource(rawSrc: string | Source): Source;
/**
 * `entryPointIndex` is the index in the `statements` array of the `main` function
 *   `entryPointIndex` is set to -1 for modules
 *   If a `main` function isn't found for a non-module script an error is thrown
 */
export type ParsedScript = {
    purpose: Word;
    name: Word;
    statements: Statement[];
    entryPointIndex: number;
};
export type ScriptPurpose = import("./ScriptPurpose.js").ScriptPurpose;
import type { Source } from "@helios-lang/compiler-utils";
import type { ErrorCollector } from "@helios-lang/compiler-utils";
import type { Word } from "@helios-lang/compiler-utils";
import { Statement } from "../statements/index.js";
//# sourceMappingURL=parseScript.d.ts.map