Releases: shakfu/psnd
psnd 0.1.6
psnd is a self-contained modal editor, REPL, and playback environment aimed at music programming languages. The project is a polyglot platform for composing, live-coding, and rendering music DSLs from one binary.
Five languages are currently supported:
- Alda - Declarative music notation language
- Joy - Concatenative (stack-based) functional language for music
- TR7 - R7RS-small Scheme with music extensions
- Bog - C implementation of dogalog, a prolog-based beats-oriented language for music
- MHS - Micro Haskell with MIDI support for functional music programming
All are practical for daily live-coding, REPL sketches, and headless playback. The Alda and Joy MIDI cores are from the midi-langs project. Languages register themselves via a modular dispatch system, allowing additional DSLs to be integrated without modifying core dispatch logic. Audio output is handled by the built-in TinySoundFont synthesizer or, optionally, a Csound backend for advanced synthesis. macOS, Linux, and Windows are supported.
| Variant | Description |
|---|---|
psnd-tsf |
TinySoundFont only (smallest) |
psnd-tsf-csound |
TinySoundFont + Csound |
psnd-fluid |
FluidSynth only (higher quality) |
psnd-fluid-csound |
FluidSynth + Csound |
psnd-tsf-web |
TinySoundFont + Web UI |
psnd-fluid-web |
FluidSynth + Web UI |
psnd-fluid-csound-web |
Everything |
Note: Binaries were released earlier in this release which were built using the 0.1.6 code-based but which mistakenly included the 0.1.3 version in the cli. This was fixed and new binaries were uploaded with the correct version.
Changes since the last Release
Fixed
- Alda Parser EOF Safety:
peek()now returns a static EOF sentinel token instead of NULL, eliminating a class of NULL pointer dereference bugs when parsing truncated or malformed input (lines 288, 534 ofparser.c) - Joy Dictionary SEQ Leak:
joy_dict_set()now frees sequence (SEQ) definitions when replacing an existing word, matching the cleanup logic already present injoy_dict_remove() - Alda Repetition Overflow: Repetition counts in
parse_rep_spec()are now capped at 10,000 to prevent integer overflow from malformed input - Joy String Primitive Safety: Replaced unbounded
strcpy/strcatwithmemcpyusing pre-computed lengths in string cons and concatenation primitives (joy_primitives.c) - REPL History Recall Safety: Replaced unbounded
strcpywithstrncpybounded toREPL_MAX_INPUT_LENGTHin the non-linenoise fallback path (repl_line_editor.c)
Added
- Alda Parser Fuzz Tests: 26 truncation fuzz tests that parse valid Alda strings at every byte truncation point, asserting no crashes (
test_parser_fuzz.c)