Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Lingua Tungga

One source for pure logic and data models that behave identically in TypeScript, Python, and Go.

package money {
  export struct Price {
    amount: Int
    currency: Str
  }

  export fn format(p: Price) -> Str {
    `${p.amount / 100}.${p.amount % 100} ${p.currency}`
  }
}

The same file compiles to three ordinary libraries. There is no runtime to install, no interop layer, and no generated code to edit:

lt build -t ts src/money.lt   # -> out/ts
lt build -t py src/money.lt   # -> out/py
lt build -t go src/money.lt   # -> out/go

What it is for

Lingua Tungga owns the part of a program that must agree everywhere: business rules, validation, money arithmetic, data models, and algorithms. It deliberately has no entry point, no UI, no IO, and no concurrency. The host language keeps those.

  • One behavior. Integer division truncates toward zero in every target. Comparison, display, and JSON follow one specification.
  • Ordinary output. TypeScript gets typed modules, Python gets typed modules with a .pyi-free runtime, Go gets packages. You import them like code you wrote.
  • No drift. The conformance suite runs the same .lt tests against all three targets.

Status

Experimental. There is no compatibility promise before 1.0; the language specification is versioned, and the compiler tracks it.

PhaseM9 — distribution
Language.lt
CompilerRust, binary lt
TargetsTypeScript, Python, Go
Conformance100% in all three targets
LicenseMIT

Where to go next