Repository navigation
Roadmap
torvik-lang edited this page Aug 24, 2026
·
13 revisions
This page outlines the current development direction for Torvik.
v1.5.4 is a patch on v1.5.0: three freestanding (--bare) link failures, no
feature changes. See the changelog.
Systems and OS development. Torvik can now produce a freestanding image that boots on
bare hardware with no operating system, no C library, and no runtime beneath it.
Everything here is opt-in and unsafe-gated — the safe surface is unchanged.
-
Raw pointers (
varda<T>), fixed arrays ([T; N], bounds-checked), andshapevalue structs, plain andpacked. A packed shape maps byte-for-byte onto a C struct or a hardware descriptor;size_of/align_ofreport compile-time layout. -
Volatile MMIO (
load_vol/store_vol), inline assembly (galdr { "hlt"; }), and named x86_64 intrinsics (cli,sti,hlt,outb/inb, …) so register constraints live in the compiler rather than in every kernel. -
Freestanding builds —
torvc --bare, an allocator hook (on_alloc/on_free) so heap types work bare, and OS builtins refused at compile time with an error that says what to use instead. The output is decided by the target, not the build host. -
A reference kernel and tutorial in
examples/kernel/— VGA text, port I/O, a long-mode boot stub, and a linker script. -
Float widths
f16,f32,f128alongsidef64, with true storage layout —shape Vec3 { x: f32, y: f32, z: f32 }is twelve bytes. -
Hex, binary and underscored integer literals —
0xB8000,0b1010_0110,1_000_000. -
Run mode —
torvc file.tvandrune run file.tvexecute a file directly. -
[build]manifest section sorune build/rune runwork for a kernel. - Major-version gating for both the toolchain and the standard library.
- The standard library moved to its own repository with its own version line.
-
&&and||now short-circuit — a correctness fix.
-
Optional (
^) and variadic (*) parameters — mark a trailing parameter^to let callers omit it (it takes a type-appropriate zero), or*to gather the remaining arguments into alist<T>. They combine in the order required → optional → variadic, and arity errors are clean located ranges. -
Comprehensive argument type-checking — a definite mismatch between an argument and its
parameter (string vs number, container vs scalar,
f64vs integer, str-list vs raw-list) is a clean located error instead of silent garbage. -
Boolean chaining is limit-free —
&&/||work as values bound to a variable, chain any number of operands, and a boolean-returning builtin or user function can be compared totrue/falsedirectly. -
std::net— an opt-in HTTP layer (apply std::net;) with request parsing, MIME types, and binary-safe file serving over transport primitives that dead-strip out when unused. Powers Vefna'svefna serve. -
chr(code)andfs_size(path)builtins; standard library v1.3.0. -
runedecoupled into its own repository, versioned independently. - Fixes: exhaustive
whenflow-checker false positive; boolean-literal argument IR;booluser-function return storage; single-character function-name resolution underapply std.
The concurrency release.
-
Ravens: concurrent tasks —
ravenspawns anydffunction on its own OS thread, fire-and-forget or with atask<T>handle collected byjoin. Arguments deep-copy at the spawn, spawned functions must be self-contained (no globals — enforced at compile time), and the reference-counting runtime stays lock-free across threads. -
Bridges: typed channels —
bridge<T>is a buffered, thread-safe queue between tasks (bridge_new/send/recv/try_recv/bridge_close). Values deep-copy on send;try_recvreturns aresult<T>that goes err exactly once the bridge is closed and drained — the clean end for a worker loop. Multiple producers and consumers are fully supported. -
Interpolation scoped to
echo,echo!, andfmt— a string literal written directly as an argument of those three interpolates as before ({name}, expressions,{{escapes). A string literal anywhere else is plain data: braces are ordinary characters, so CSS, JSON, and template text need no escapes. -
Variadic
str_concat— folds any number of arguments left to right; a one-argument call is a clean compile error instead of a silent drop. -
Table iteration —
table_keys(t)returns every key as a sortedlist<str>, so loops over a table are reproducible. Also fixed: functions returning atableorbagno longer hand back freed memory. -
File-system surface for real tools —
dir_list,fs_is_dir, binary-safefs_copy, and recoverable I/O viatry_writefile/try_appendline/try_fs_copy, plus anunused_resultwarning category. -
Standard library v1.2.0 — a new
std::convertmodule (base conversions, safe parsing) plus additions acrossstd::strings,std::list, andstd::math.
v1.3.0 also powers Vefna, a parallel static site generator written entirely in Torvik — it renders pages on eight raven worker threads and wove the Torvik website.
-
v1.2.1 — patch: warnings reach
rune runusers, unannotated declarations no longer silently compile broken, clearer bare-builtin errors, correct line numbers underapply. -
v1.2.0 —
aettenumerations with exhaustiveness-checkedwhenpattern matching, the compile warnings system, completedresult<T>error handling,find(), independent standard-library versioning, and Windows.tvfile-type icons. -
v1.1.x — expression chaining everywhere, full 128-bit integers, weave argument
insertion, block comments, direct collection iteration, expression interpolation,
rune update/ fullrune uninstall, symlink-safefs_remove, reproducible Windows builds — and full Windows (x86-64) support. -
v1.0.0 — the self-hosting milestone:
torvcandrune, written in Torvik, compiling themselves to a byte-identical fixpoint.
-
Flow analysis: exhaustive
when— awhenover an aett that covers every variant, with every arm returning, will satisfy the must-return check directly (today the idiom is assign-then-return). Planned as a post-v1.3.0 patch.
- Official macOS support — needs real Apple hardware for credible testing (Apple Silicon ABI, Mach-O linking, codesigning); scheduled once hardware access is sorted.
-
shape— structs / record types. -
pub— visibility / export control. -
f32, a dedicatedchartype, and fixed-size arrays ([T; N]). -
\u{...}Unicode escapes.
-
Method syntax — method-style calls on standard-library types (e.g.
s.str_cmp(t)); the library keeps growing as plain functions in the meantime. -
Rune Library — the package registry (
rune add/remove/updateagainst a[runes]section). A substantial project with real hosting costs; timeline depends on planning and sponsorship.
- Cycle detector — detect and reclaim reference cycles, ahead of constructs (nested mutable containers) that could create them.
- C → Torvik runtime port — migrate the C runtime to Torvik over time.
- Check the Releases page for updates
- Watch the repository for new activity
- Join Discussions to share feedback
The roadmap is living and will evolve based on community input and development priorities.
- Find out how to Contribute to Torvik.
- Have any questions? See our FAQ.
Last updated: August 2026 (v1.5.4)