Explore Lesma
Lesma is a compiled, statically typed, imperative, object-oriented language that targets LLVM. Install the toolchain, read the language tutorials, use the CLI and editor support, and try code in the browser playground.
Foundations
Get started
Install a release or build the compiler from source, then write and run your first program.
Installing Lesma
Use the installer script or build from source with CMake, vcpkg, and LLVM.
A Tour of Lesma
A longer example with comments: no main function, imports, types, classes, and control flow.
Your First Program
Create a small program and run it with the `lesma` CLI.
Editor & Language Server
VS Code extension and `lesma-lsp` for diagnostics, completion, and navigation.
Language
The Lesma language
Progressive tutorials covering types, functions, control flow, classes, traits, generics, and modules.
Tooling
Command line
Run and compile programs with the `lesma` CLI, including optimization flags for release builds.
Guides
Practical guides
Short recipes for everyday tasks using the standard library: files, console I/O, math, randomness, and sleep.
Reading and Writing Files
Use the `file` type to read text, write bytes, and delete paths.
Console Input and Output
`print`, `input`, and C-style `printf` when you need precise formatting.
Random, Time, and Sleep
Inclusive `random`, wall-clock `time`, and `sleep` from the `time` module.
Using Math
Import `abs`, rounding, and trig helpers from the `math` module.
Repository
Source code, issues, and releases live on GitHub. Contributions follow the usual pull request workflow.
github.com/alinalihassan/Lesma →