Sigmal is a modern programming language built on a tiny, symbolic, and mathematically sound core. Every Sigmal program is total, pure, and deterministic β yet expressive enough to build real software, compilers, and safe metaprogramming systems.
Sigmal aims to bridge logic and engineering, offering a foundation strong enough for proofs and practical enough for everyday code.
Sigmal programs always terminate. No unbounded loops. No undefined behavior. No surprises.
If a computation isnβt total, it simply isnβt Sigmal.
Every Sigmal function behaves like a mathematical function:
Same input β Same output Every time.
No hidden state. No mutation. No uncontrolled effects.
Real-world effects (I/O, state, async) are expressed through explicit effect layers built on top of Sigmalβs safe core.
The entire Sigmal core consists of just five symbolic constructs:
\ β functions^ β dependent function types& β dependent records? β pattern matching# β inductive typesFrom these pieces, Sigmal builds:
All as elaborations of this minimal calculus.
Modules in Sigmal are ordinary values β not compiler magic.
A module is just a Ξ£-type record. A functor is just a function from modules to modules. A macro is just a module-transforming function.
This unlocks:
Sigmal treats meta-programming as programming.
The core of Sigmal erases to a clean, low-level IR with predictable memory layout.
Sigmal can target optimized native code with:
Totality + purity + explicit memory models make low-level optimization safer than ever.
Sigmal is designed for developers who want the confidence of formal systems without the heaviness.
Sigmal code can be both proved and deployed.
Example snippets in raw Sigmal Core:
(# Bool () Type0
(True Bool)
(False Bool))
(\ (b Bool)
(? b
(True False)
(False True)))
(& (T i32)
(zero 0)
(add (\ (x i32) (\ (y i32) (+ x y)))))
Everything else is built on top of these constructs.
Sigmalβs promise is simple:
Small. Pure. Total. Extensible. A language you can reason about. A language you can optimize. A language you can grow.
Sigmal is new, experimental, and growing. Join us as we build a language that treats correctness, clarity, and expressiveness as first-class citizens.
π Documentation π Examples π GitHub π Community
sigmal.org β the calculus we can build on