import type { SpecClause } from "./sections.js"; export type TypeKind = "number" | "vector" | "reference" | "form"; export interface TypeEntry { /** Type or type-form name, e.g. `i32`, `funcref`, `functype`. */ name: string; /** Classification of this entry. */ kind: TypeKind; /** Defining clause anchor, e.g. `syntax-numtype`, `syntax-functype`. */ anchor: string; /** For category types: the sibling concrete types (e.g. the four * number types). Empty for type forms. */ members: string[]; /** Defining clause title, e.g. `Number Types`. */ title: string | null; /** Defining clause prose. */ prose: string; /** SpecTec rule / syntax names referenced by the defining clause. */ formal_refs: string[]; /** Rendered spec URL for the defining clause. */ url: string; } /** Raw macro shape as emitted by src/parser/upstream.ts. */ interface RawMacro { body: string; kind: "instruction" | "type" | "other"; category: string | null; section: string; anchor: string; } /** * Build the type catalog. `macros` is the dumped macro table; * `typeClauses` is the parsed `syntax/types` section. */ export declare function buildTypeCatalog(macros: Record, typeClauses: SpecClause[]): TypeEntry[]; /** Look up one type by name (case-insensitive, exact). */ export declare function getType(catalog: TypeEntry[], name: string): TypeEntry | null; export {};