plum

#treesitter#compiler#wasm

git clone https://git.pyrossh.dev/plum

A statically typed, imperative programming language inspired by rust, python


e81d9ee — Peter John 2026-11-13T18:28:46+05:30
examples, benchmarks, web-test fixtures: no top-level funs but main (366 moved) and no top-level constants; each example's funs about one of its types are methods or statics of it (`c.spin()`, `w.asInt()`, `House.parse`), the rest a `primitive` named after the file (`Recursion.sumTo`, `StructsRecords.pick`, `Basics.MaxRetries`); the games' helpers are statics of their screen or actor (`PlayingScreen.starsFrom`, `Balloon.burst`, `Particle.step`, `e.applyTo(world)`, `Assets.MusicVolume`), their test-only helpers in the tests/ mirror's `PlayingScreenHelpers`/`PlaygroundScreenHelpers`, BalloonPop's `playground` inlined into `main`, `TwoScreens.game()`; benchmarks in `FibBench`, `Timing`, `MathCheck` .., static_calls compares a static with a `primitive`'s (0.58 s both; free fns are gone), run.py's game drivers compile again (`OrbRun`, `BalloonRun`, `std/game/Input`, `Held.keysOnly`); web-test fixtures' `page` upcast is a typed local, `Stress`/`Interleave` keep their constants and drawing; std constants in types: `Slice.SortRun`, `JsonParser.MaxDepth`, `TestRig.DefaultW`/`DefaultH`, `Effects.Running`; loader: a namespace `primitive` is allowed in any file, a built-in's or an extension (type parameters, a `self` fun, a type of the file's name) still only in std and tests; checker and codegen: a static is a value (`call(Recursion.dec, n)`, `f := Rec.twice`) through the free fn's trampoline, typed as its fn; formatter: a blank line before a comment in a primitive's body is kept; tests (loader, modules, codegen static value, formatter), tests/examples and tests/benchmarks callers; docs (language.md: statics, constants, traits and modules samples; std.md, game.md)

This diff is too large to display.