import { Span } from "../diagnostics.ts";

export type File = {
    stmts: Stmt[];
};

export type Stmt = {
    id: number;
    kind: StmtKind;
    span: Span;
};

export type StmtKind =
    | { tag: "error" }
    | { tag: "mod_block" } & ModBlockStmt
    | { tag: "mod_file" } & ModFileStmt;

export type ModBlockStmt = {
    ident: string;
    stmts: Stmt[];
};

export type ModFileStmt = {
    ident: string;
    filePath: string;
};