Skip to content

ditto-lang/ditto

Repository files navigation

ditto

A small, pure functional language that targets other languages.

GitHub release (latest by date) CI status Security audit status

Hello world program in ditto
Syntax highlighting coming soon

Elevator pitch ⏱️

Ditto is a mashup of my favourite features from other languages.

It's functional, statically typed, and pure. But unlike many other languages in this category, it also aims to be ruthlessly simple - the syntax is small and the type system is low power.

It has no runtime of its own. There are far more mature compilers and ecosystems out there that I want to make use of, and would be naive to try and replace. So ditto can be thought of, instead, as an alternative syntax for other tools.

Ditto is not just a compiler, it's the language swiss army knife. Package management, linting, formatting, etc, are all handled by the ditto executable. Although this violates the Unix philosophy it is my hope that it makes for a better developer experience. Because developer experience matters.

Disclaimer ⚠️

Ditto is still pre-v0.1 and very unstable. It is only for the curious at this stage.

Design notes

  • "There should be one - and preferably only one - obvious way to do it." - Zen of Python
  • "Small is beautiful" - Lua design
  • "Clear is better than clever" - Go Proverb
    • Alternatively, "Verbose is better than terse" - Me
    • Optimise for reading and understanding, not for writing.
  • Best practice over backwards compatibility 🔥
  • Anti-magic. Anti-fancy.
  • Safe by default, but explicit escape hatches when you need them.
  • Embrace code generation.