Features · amc v0.8.18 · 480/480 tests

The best of every language.
Compiled to a native binary.

Pattern matching from OCaml. Null-safety from Kotlin. Comprehensions from Python. Pipelines from Elixir. String interpolation from C#. ADTs from Haskell. No VM, no heavy runtime, no fork-of-a-fork piling features on top of each other. A statically-typed language that compiles to portable C and rebuilds itself in 5 seconds.

You already know Amalgame

Every feature we picked has a known parent. Here are the direct mappings.

Foundations

What Amalgame is, at its core.

Self-hosted & hackable

amc is written in Amalgame. It rebuilds itself in 5 seconds — change the language, test, change again. Where Rust takes an hour and Go several minutes, here the "I have an idea, let me try it" loop stays fluid. And if you break the binary mid-dev, a known-good snapshot/amc_lib.c + a single gcc brings back a working compiler.

Compiles to C, native binary auto-generated

Full pipeline in one command: your .am becomes readable C, then a native gcc -O2 binary, no manual step. Source maps 1:1: stringchar*, Listvoid**, inti64. No VM, no hidden allocation beyond the GC (Boehm). Ready to ship.

Cross-platform

Linux, macOS and Windows (via MinGW) — every v* tag produces all three binaries. Green CI on all three OSes on every commit. The runtime sits behind a clean #ifdef _WIN32 on the networking layer (Winsock vs POSIX).

480
passing tests
5s
compiler rebuild
(vs ~1h for Rust)
3
supported OSes
0
VM, custom GC, mystery runtime
⚡ The language

Everything a dev expects in 2026, in a single language

No feature that needs you to "wait for a release". It's all here, today.

Pattern matching

Match as expression, with guards and destructuring

match is an expression — you can assign it to a let. It supports guards (x if x > 0), ranges (1..9), binders, and ADT destructuring.

let bucket = match n {
    0           => "zero"
    x if x < 0  => "negative"
    1..9        => "small"
    10..99      => "medium"
    _           => "large"
}

match shape {
    Circle(r)  => Console.WriteLine("r={r}")
    Rect(w, h) => Console.WriteLine("rect")
}
Null-safety

The compiler stops you from dereferencing null

Nullable types are distinct (T? vs T). Safe access (?.) and the coalescing operator (??) are built-in — like Kotlin, without the Java nullable-annotations folklore.

let maybe: Greeter? = null
let label = maybe?.Hello()      // null-safe
let name = user?.Name ?? "anon"
guard name != null else {
    return
}
Comprehensions + pipeline

Code reads the way you think it

List comprehensions (Python), pipeline operator (Elixir/F#), higher-order list methods (Filter, Map, Reduce, Any, All, CountIf) with capturing closures.

// Comprehension
let squares = [i * i for i in 0..10 if i % 2 == 0]

// Higher-order chain
let total = numbers
    .Filter(n => n > 0)
    .Map(n => n * 2)
    .Reduce(0, (acc, n) => acc + n)

// Pipeline
let shouted = name |> String.ToUpper |> String.Trim
String interpolation

Native interpolation, multiline included

No more concat soup. Expressions go between {}, and triple-quoted """...""" handle multiline templates. \xHH and \uHHHH escapes supported.

let msg = "Bonjour {user.Name}, tu as {orders.Count()} commandes"

let sql = """
    SELECT id, name
    FROM users
    WHERE created_at > '{since.Format()}'
    ORDER BY name
"""
Algebraic enums (ADT)

Tagged unions with payload, verified by the compiler

Like OCaml, Rust or Haskell. Each variant can carry its own data. Pattern matching destructures cleanly, the typechecker reminds you of forgotten variants.

public enum Result {
    Ok(int)
    Err(string)
}

match compute() {
    Ok(v)    => Console.WriteLine("value: {v}")
    Err(msg) => Console.WriteLine("error: {msg}")
}
Generics + verified interfaces

Compile-time checking, runtime erasure

Generics are erased to void* at the C level (compact binary, no symbol explosion), but their signature is verified by the compiler. Generic interfaces substitute the parameters and enforce contracts.

public class Box<T> implements IComparable<int> {
    public Value: T

    public int CompareTo(int other) {
        return 0
    }
}
Closures & lambdas

Capture by value, multi-arg, blocks

Lambdas (x, y) => expr capture the surrounding scope into a GC-allocated env struct. Block bodies x => { ... } are supported. Everything works through the higher-order list methods.

let threshold = 10
let big = xs.Filter(x => x > threshold)

let combine = (a, b) => {
    let sum = a + b
    return sum * 2
}

Tuples + destructuring · guard clauses · decorators @inline/@deprecated · bitwise ops · compound assignments · range 0..n · try/catch/throw · classes, inheritance, interfaces, data classes, records

🔌 Native VSCode integration

Every modern tool, inside your favorite editor

Official extension shipped in the repo. Workspace-aware LSP, native DAP with breakpoints on .am. Everything is there, at install.

🎬

VSCode experience demo coming soon.

LSP autocomplete in action, live diagnostics, breakpoint on .am via DAP.

Official VSCode extension

Shipped in editors/vscode/ in the repo. Syntax highlighting + LSP client + pre-configured amc debug type. One-command install: amc new --vscode even scaffolds a .vscode/launch.json ready for F5.

amc lsp — Language Server

Workspace-aware: scans every .am under the root to resolve cross-file types. Live diagnostics (didOpen/didChange), hover with inferred type, global completion, signatureHelp.

amc dap — Debug Adapter

DAP proxy that detects lldb-dap (LLVM 18+) or gdb --dap (gdb 14+). The #line directives emitted by cgen make your breakpoints set on .am resolve natively via DWARF — no source maps, no path translation.

amc fmt — Formatter

Re-emits the AST canonically, preserves comments. Idempotent on every compiler source. amc fmt -w to rewrite in place.

amc --lint — Static linter

Flags unreachable code, unused locals (prefix _ to silence), shadowed names. Warnings non-fatal — no friction to get started.

amc test — Test runner

No framework. Discovers *_test.am, compiles, runs, aggregates [PASS]/[FAIL]/[SKIP]. Exit non-zero if anything breaks.

amc lsp  ·  amc dap  ·  amc fmt -w src/  ·  amc --lint  ·  amc test

The extension also works with Neovim, Helix, Emacs (eglot) and any standard LSP/DAP client.

LLM multipliers

Three commands to migrate, generate and explain code. Your key, your data, your provider.

amc migrate

21 source languages auto-detected (TS, Python, Java, C#, Go, Rust...). SHA-256 cache, cost estimation in --dry-run, auto-validation with amc --check.

amc generate

Prose → Amalgame. Perfect to scaffold a starting point. --stream for direct stdout passthrough via the claude CLI.

amc explain

Code → prose. --lang French (or any other language) translates the explanation.

Provider of your choice: Anthropic (Claude), OpenAI (ChatGPT), Google (Gemini), or claude CLI as fallback. Auto-detection from ANTHROPIC_API_KEY / OPENAI_API_KEY / GEMINI_API_KEY. No server we control in the pipeline — direct HTTPS from your machine to the provider.

📦 Ecosystem

A modular library that grows every week

22 official packages available today, 15 on the roadmap. All Apache-2.0, all managed via amc package add <name>.

🗄️ Databases SQL + NoSQL

AvailablesqliteSQLite 3 vendored, public-domain, no dev-dep.
AvailableduckdbOLAP analytical, vectorized execution.
AvailableredisPure RESP2, no vendored lib. KeyDB/Dragonfly/Valkey compat.
AvailablepostgresqlDynamic-linked to system libpq, no vendored lib. First package using the dynamic-link pattern.
Coming soonmysqlMySQL / MariaDB via libmariadbclient.
Coming soonoracleOracle Instant Client (OCI), session pooling.
Coming soonmssqlMS SQL Server via ODBC or FreeTDS.
Coming soonmongoMongoDB via libmongoc + BSON.
Coming sooncassandraNative CQL — Cassandra / ScyllaDB.
Coming soondynamodbDynamoDB / Cosmos / Firestore via HTTP.
Coming soondatabase-ormCross-engine or per-family ORM layer (TBD).

📡 Messaging & networking

AvailablemqttMQTT 3.1.1 pure protocol, QoS 0.
Availablenet-websocketRFC 6455 client, text frames, in-process SHA-1+Base64.
Coming soonnatsNATS Core, pub/sub + request/reply, text protocol.
Coming soonkafkaApache Kafka via librdkafka.
Coming soonrabbitmqAMQP 0.9.1 via librabbitmq.

🎨 UI & graphics

Availableui-webWebview-based: WebView2 / WKWebView / WebKitGTK + JS↔AM IPC.
Availableui-sdlSDL2/SDL3 binding — foundation for custom graphics.
Coming soonui-glOpenGL 3.3 core — GLProgram / GLBuffer / GLTexture.
Coming soonui-gfx2dGradients, polygons, Bezier, PNG/JPG loading.
Coming soonui-vkVulkan binding (priority once OpenGL stabilizes).

🎵 Multimedia

AvailableimageDecode/encode PNG/JPG/BMP/TGA/GIF/PSD/HDR via stb_image vendored.
AvailableaudioSynth + playback + WAV IO via miniaudio vendored (public domain).

🛠️ Standard framework

Availablemathsqrt/sin/cos/pow/log, constants, IsPrime.
Availablemath-vecVec3 / Vec4 / Mat4 column-major (OpenGL).
AvailabledatetimeInstant ns-UTC, Duration, Stopwatch, ISO 8601.
Availablelogging4 levels, ISO 8601 UTC, optional file sink.
AvailableserviceSIGTERM/SIGINT + Windows SCM dispatcher.
Availableio-filewatcherCross-OS mtime polling.
AvailableregexPOSIX ERE, Test / Match / Replace.
AvailableyamlYAML 1.2 subset reader.
AvailableencodingBase64, Hex, percent-encoding.
AvailablecryptoPure SHA-256 + HMAC-SHA-256, no OpenSSL.
AvailablerandomPCG-32 + crypto-grade entropy.
Availablecompresszlib gzip + raw-deflate on List<int>.
Coming soonmsgpackMessagePack 1.0 subset codec.
Coming soonthreadingThread pool + Mutex + Channel.
amc package add duckdb  ·  amc package search ui  ·  amc package versions kafka

The official package manifest lives at amalgame-lang/packages-index. Third-party packages work via direct URL.

Trust & quality

Zero telemetry

amc runs entirely on your machine. No phone-home, no usage stats, no pixel tracker in the binaries. The amalgame.me site serves static docs, full stop.

Your key, your data

LLM commands (migrate / generate / explain) call your provider directly with your key. No amalgame.me server in the pipeline — no middleman, no remote cache.

Green multi-OS CI

Every commit runs on Linux + macOS + Windows MSYS2. Releases are produced automatically on every v* tag via GitHub Actions.

Apache-2.0 everywhere

Compiler, runtime, stdlib, every official package: Apache 2.0. No commercial dual-license, no contributor gray zone.

rustc-style diagnostics

Errors come with source snippet + caret pointing at the token. Resolver and type-checker each have their category. No generic "syntax error at line 42".

Recoverable bootstrap

If ./amc breaks mid-dev, snapshot/amc_lib.c + one gcc brings back a working compiler. No mystery tape, no opaque circular dep.

Ready to try?

Install takes 30 seconds. The language is young — your contribution counts.