Experimental programming language

Lume programming language

Readable types. Explicit flow. Java reach. Lume is designed for direct application code with nominal classes, structural shapes, exhaustive pattern matching, and practical Java interoperability.

users.lum
shape UserView {
    name Str
    active Bool
}

fn loadUser(id Int) Result[UserView, DbError] = {
    row = try Db.queryRow(
        "select name, active from users where id = ?",
        id
    )

    Ok({
        name: row.str("name")
        active: row.bool("active")
    })
}
Language model

Different tools for different kinds of data

Lume does not force every concept into one object model. The language separates identity, structural data, alternatives, behavior, and singleton values.

Classes and shapes

Classes are nominal runtime entities. Shapes are structural views with shallowly read-only field bindings; referenced values retain their own mutability rules. Classes can expose public fields as shapes without becoming structurally interchangeable classes.

Explicit failure

Option, Result, and Either make absence and failure visible. try, pattern bindings, and explicit transformations keep propagation concise.

Java ecosystem

The compiler validates Lume source before generating Java. External Java classes can be described as Lume-compatible types while backend-specific details stay outside the language model.

Current status

A working language under active design

Compiler

Implemented in Rust with lexing, parsing, name resolution, type checking, desugaring, lowering, diagnostics, and checked execution.

Backends

The repository contains an interpreter path and Java source generation used by Gradle examples and Lume libraries.

Libraries

A small standard library plus Lume-authored core, JSON, database, and HTTP modules exercise the language against real application code.

Stability

Lume is experimental. Syntax and runtime behavior are still evolving, so it is a language to explore and contribute to rather than a production compatibility promise.

Next step

Read it, run it, inspect it

Start with the installation and CLI guide, then use the language tour for the core mental model. The complete evolving reference remains in the repository.