Vanta is a small statically-typed language that compiles to C++17. It is designed for high-performance game code: predictable memory, explicit mutability, built-in vector types, and a stack-scoped arena allocator.
Vanta is a Python package with a native compile step, so it needs:
Install the vanta command with pipx (recommended) or pip:
pipx install vanta-lang # or python -m pip install vanta-lang Check the install and the toolchain:
vanta --version vanta doctor vanta doctor reports the Python version, the C++ compiler it found, the installed runtime header, and whether SDL2 is available for games. Non-game programs only need the C++ compiler; the game kit additionally needs SDL2, SDL2_ttf, and SDL2_image.
For compiler development, install an editable checkout instead:
python -m pip install -e . Quick start Write a program:
vanta check hello.vnt # type-check only (fast, no C++) vanta hello.vnt # shorthand for `vanta run hello.vnt` vanta build hello.vnt --release Diagnostics print the offending source line and a caret under the reported column. Source files may start with a UTF-8 BOM.
Arguments after the source are passed through, so vanta report.vnt 3 reaches the program. In a checkout, the same commands work on the examples:
vanta examples/vector_math.vnt vanta examples/strike.vnt Modules A file can begin with module name and export declarations with pub. import "lib.vnt" brings a module's public names into the importing file; import "lib.vnt" as lib uses qualified names such as lib.func(...) and lib.Type(...). Files without a module declaration keep the original flat, all-public import behaviour. See the module example and the language reference.
v0.31.0 adds generic enum declarations and a small standard library. import "std/option.vnt" provides Option (None/Some(T)) for values that may be absent, and import "std/result.vnt" provides Result (Ok(T)/Err(E)) for success-or-error APIs. Both are ordinary enums, so match destructures them exhaustively; constructors infer their type arguments from the expected type or payload, with Option.None:: () and Result.Err:: ("missing") as the explicit forms. See examples/option_result.vnt and the reference.
Start a new game with a playable paddle-and-ball starter:
vanta new game.vnt vanta game.vnt The starter imports the game kit from the installed compiler, so vanta new works the same from a checkout or a wheel install. Build a shareable Windows bundle — the executable, its runtime DLLs, the example assets, and the kit font go into one folder:
vanta build examples/strike.vnt --release --bundle .\build\strike\strike.exe run compiles to a temporary executable and deletes it afterwards. build writes to build/ (or -o ), and --emit-cpp also writes the generated C++. On C++ compilation failure the generated source is saved to build/vanta_failed.cpp for inspection.
vanta lsp It speaks LSP over stdin/stdout and provides diagnostics, completion, hover, go-to-definition, and document symbols. The VS Code client in editors/vscode/ adds those features on top of the existing syntax highlighting; install the VSIX from the latest GitHub release or build it from source. The server reads unsaved buffers, so diagnostics also work before a file is saved.
The client finds vanta on PATH, in a workspace virtualenv, or through a Python environment that can import the compiler. Set vanta.server.path to override discovery. See docs/EDITOR.md for setup, settings, and troubleshooting. Debugging is not part of this milestone.
extern blocks declare functions implemented in C; the driver links the library in:
extern "SDL2" { func SDL_Init(flags: u32) -> i32 } --include-dir, --lib-dir, and --link are repeatable flags on build and run. On GCC-style toolchains they become -I, -L, and -l; on MSVC they become /I, /LIBPATH:, and .lib. The SDL libraries the game kit uses are detected from their extern block names — extern "SDL2", "SDL2_ttf", and "SDL2_image" — and linked automatically. A self-contained example ships with its C side in examples/extern_demo_lib.c:
gcc -c examples/extern_demo_lib.c -o build/extern_demo_lib.o ar rcs build/libdemo.a build/extern_demo_lib.o python main.py run examples/extern_demo.vnt --lib-dir build --link demo See docs/LANGUAGE_REFERENCE.md for the declaration rules.
vanta examples/sdl_game.vnt vanta examples/sdl_text.vnt vanta examples/sdl_texture.vnt vanta examples/sdl_audio.vnt vanta examples/sdl_gamepad.vnt vanta examples/pong.vnt vanta examples/breakout.vnt vanta examples/strike.vnt All of them are pure extern declarations, so no SDL headers are needed to compile. The windowed examples take an optional frame-limit argument for headless smoke runs (SDL_VIDEODRIVER=dummy), and the audio examples run under SDL_AUDIODRIVER=dummy, which plays to nowhere in real time. The kit ships its own font (examples/gamekit/fonts/tom-thumb.ttf, a tiny 3x5 pixel face), and the example images and WAVs in examples/assets/ are generated by a committed script (gen_assets.py) — nothing is vendored.
python -m unittest discover -s tests Integration tests compile and run real binaries, so they need a C++17 compiler on PATH; they skip automatically if none is found. To force a specific compiler, set the CXX environment variable.
Vanta is a prototype, not a finished language. Programs can span multiple files with optional module scopes, qualified imports, and pub visibility, link against C libraries (callbacks and enum types included), read command-line arguments, produce formatted output, read and write files, build 2D grids, pass functions around, bounds-check array access with xs.at(i) and pointer access with p.at(i, size), grow, edit, and sort arena-backed lists (List ) and walk lists and arrays with for x in xs, store exact-width integers (i8/u8/i16/u16) whose memory layout matches C, compare structs field by field with ==, reinterpret pointers with ptr_cast:: (p), step them by elements with ptr_offset(p, n), build explicit nulls with ptr_null:: (), build strings incrementally with StrBuilder, own runtime strings with automatic reference counting, name states and modes with enums (including explicit values, payloads, and generic instances), use the shipped Option/Result library, branch on enum values exhaustively with match, and build and run real SDL2 games on the game kit, text rendering, sprite images, sprite-sheet animation, and WAV sound files included (nine SDL examples, four of them playable games) — but the remaining gaps are real:
Editor support covers diagnostics, completion, hover, definition, and document symbols through vanta lsp and the VS Code client. There is no debugger or DAP adapter yet, and generated C++ is not source-mapped back to Vanta lines, so stepping through Vanta source is future work.
These are tracked, prioritised, and sized in ROADMAP.md.
All 2 files in this release have provenance metadata.
language compiler gamedev systems-programming
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 21, 2026.
All 2 files in this release have been uploaded with provenance metadata.
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.




