C17 implementation of the Prefix programming language.
This repository contains the reference implementation of the Prefix programming language, written in ISO C17 and targeting Clang on baseline x64. The codebase includes the lexer, parser, interpreter/runtime, standard library bindings, and supporting tools used by the reference implementation.
Supported platforms:
- Windows Vista or newer.
- Ubuntu 22.04 or newer (x86_64).
.github/workflows/: GH Actions CI configuration.docs/: Documentation for Prefix, builds GH Pages site.ext/lib/src/: Source code and headers for the interpreter.tests/: Automated test suite..gitignore: Git ignore file.build.ps1: Build script for the interpreter and tests.README.md: This file.
- LLVM/Clang toolchain with C17 support.
- LLD linker (installed with LLVM on most platforms;
lldpackage on Linux). - PowerShell (
pwsh) to run the included build and test scripts.
On Ubuntu 22.04+:
sudo apt-get install clang lld powershellOn Windows: install LLVM/Clang and PowerShell (or use the built-in Windows PowerShell).
To build the interpreter run:
pwsh ./build.ps1The build.ps1 script invokes Clang and produces the interpreter, standard library, and test binaries.
Ensure your Clang installation is on PATH before running the script.
Automated tests live under the top-level tests/ directory. You can run the test harness with PowerShell:
pwsh ./tests/test.ps1The docs are located in docs/.
Prefix is distributed under the Unlicense.
Prefix follows SemVer 2.0, treating the specification as the public API.