Commit Graph

3 Commits

Author SHA1 Message Date
Michael Schimmel 13dc6beb52 Refactor tail call resolution logic
The tail call resolution logic was duplicated in `Environment::call` and
`VM::run`. This commit extracts the tail call resolution logic into a
single method `VM::resolve_tail_calls` and uses it in both places.

Additionally, this commit adds support for series indexing as a form of
tail call, allowing for direct access to series elements through the
`series(index)` syntax. This is useful for back-referencing in
time-series data.

A new example `err.myc` is added to demonstrate basic series usage and
error handling.
2026-03-06 12:35:00 +01:00
Michael Schimmel b9d88f019e Remove unused err.myc example
Update benchmark output for soa_series.myc.
Also, fix the tester to not panic when a baseline is missing, and
instead just report it as missing.
2026-03-06 12:07:39 +01:00
Michael Schimmel 32a1f21463 Add language specification document
This commit introduces the BNF for the Myc language, along with its core
semantics, data types, and evaluation logic. It also details the macro
system and provides an overview of the standard library. This document
serves as a foundational context for LLMs to understand and generate Myc
code.
2026-03-06 11:35:18 +01:00