snail-scheme
snail-scheme is a statically-typed Scheme successor. It has S-expressions, hygienic
macros, explicit types, and capabilities passed as values. Records are mutable heap objects
that any number of names may share; primitive values stay unboxed, and the
collector reclaims what nothing reaches. Functions use the Fn type former
with the Unicode → separator.
A top-level definition is a value: its initializer runs at most once, on the first read, changes nothing, and every read shares the result. A function definition is shorthand for defining a lambda. Arrays have a fixed length and mutable elements.
This is one language, with no R7RS compatibility layer, call/cc or
dynamic-wind. The compiler emits WasmGC and compiles itself; a small Chez
adapter runs its source for the first bootstrap.
These chapters describe the language:
- Terms: programs, libraries, language forms and toolchain names.
- Types: scalars, data, typeclasses, foreign functions, linked files and dynamic values.
- Capabilities: capabilities as values, how
mainasks its target for them, and what a signature does not say. - Suspension: prompts, exceptions, generators and a
one-shot
resume. - Values: sharing, mutable records, closures, resources and their representation.
- Macros and generated libraries: hygienic expansion and explicit build-time producers.
- Notable omissions: what was left out, and why.
- References: influences and further reading.
Building programs covers applications, workspaces, builds, the toolchain and the compiler; the library reference lists every library; and proposed typed state is an API for review, not implemented functionality.