Add multi-root bundle support across the toolchain:
- `compile`: Accept multiple definition names via `-x NAME` (repeatable or
comma-separated). Exports all requested definitions as named roots in a
single bundle. Defaults to "main" when no names are given.
- `export`: Accept comma-separated hashes in the positional argument and
multiple `-n`/`names` flags. Exports all resolved roots in one bundle.
- Server: Add `GET /bundle/roots?n=...&h=...` endpoint that resolves
multiple stored-term names and/or raw Merkle hashes, returning a single
bundle containing all of them as roots.
- Wire: Export `defaultExportNames` helper for generating default export
names when none are supplied.
- Drop `cereal` dependency from `tricu.cabal` (no longer used).
Introduces a read-only HTTP server (WAI/Warp) backed by the content
store, exposing three bundle-export endpoints:
- GET /bundle/name/:name — export by stored term name
- GET /bundle/hash/:hash — export by full Merkle hash
- GET /terms — plain-text listing (debug)
Also adds `tricu server` (aka `--serve`) CLI mode, move `resolveExportTarget` /
`namesForHash` / `looksLikeHash` out of `Main.hs` into `ContentStore.hs`,
and cleans up unused exports and imports across `FileEval.hs` and `Wire.hs`.
To encourage organizing code in a way that helps in understanding, I
have implemented the common idiom of requiring a `main` function. In
tricu and other functional languages, it is usually placed near the top
of the module. The evaluator gracefully handles the situation of passing
multiple files where the intermediary "library" files do not have main functions.
This new output form allows easy piping to the decode function of the
tricu executable. Includes a new test for roundtrip evaluation of map,
compilation to tree calculus terms, and decoding back to a human
readable string.
Adds CLI options for compiling to a Tree Calculus, AST, Ternary, and
ASCII tree view. Adds CLI command for attempted decoding of a compiled
result to Number/String/List.
Architectural changes to lambda evaluation and parsing to allow
for correct expression evaluation. Contains several failing AI-generated
tests and we're still failing tests for erroring incomplete definitions
Includes better error handling, additional tests, parsing and lexing
fixes to match the desired behavior defined by the new tests, and a very
basic REPL implementation.
Implemented evaluation of tree calculus terms alongside referentially
transparent variable identifiers. Implemented evaluation of defined
functions into tree calculus.