IN YOUR BROWSER / WEBASSEMBLY

Playground

Run ThreadOne code and see real output or errors. The browser interpreter reuses the SDK parser and type checker in WebAssembly.

Run supports pure functions, scalars, nominal enums, immutable lists, records, Optional values and error recovery. HTTP, JSON, database, network, file imports, timers and other I/O require the native SDK; unsupported execution returns an error.
Ready. Select Run to execute, or Check code to inspect Rust.

64 KiB source/output · 100,000 execution steps · 64 calls · 1 MiB cumulative string/record/list allocation · 8-second worker timeout. Stop terminates the worker; every run starts fresh.

Browser runtime and native SDK

The browser executes a bounded AST interpreter in a Web Worker. It does not run the emitted Rust or measure native speed. Check code only checks types and shows Rust; the native SDK compiles through Rust/LLVM and provides its documented I/O runtime.

Playground execution guide

Single-thread benefits and limits

One application thread makes state changes easier to reason about and order between suspension points, while reducing shared-memory locks and synchronization. Requests may still interleave while waiting; database transactions and per-key ordering remain application responsibilities.

CPU-heavy work can block a single application thread. Multiple threads can use several cores for parallel computation, with synchronization costs when sharing state. Neither model is faster for every workload; ThreadOne does not yet provide a thread-per-core scheduler.