yomi-core
English | 日本語
詠めば、動く。 (Recite it, and it runs.)
The core of the yomi language: parsing, type checking, the VM and saves. yomi is a small, statically typed scripting language that you embed in a Rust application. A running script can stop in the middle, have its state saved as bytes, and resume later.
use ;
let mut reg = new;
reg.?; // a command that stops the script and asks the host for an integer
let program = compile.map_err?;
let mut vm = new?;
let Stop = vm.run? else ; // stops at `@ask`
let bytes = vm.save?; // save the stop point
// Later (even in another process), resume
let = load?;
vm.resume?;
assert_eq!;
- The standard packages (
flow,math,text,json,audio,image,screen,input,event) are inyomi-std. - The
yomicommand (checking, running, REPL, Language Server, MCP server) is inyomi-cli. - The specification of the language and the host integration is in
spec/of the repository (written in Japanese).
While the version is 0.x, the grammar, the API and the save format may change.
License
Licensed under either of MIT or Apache-2.0, at your option.