Overview
This is a curated collection of resources on specialized programming languages executed by decentralized peer-to-peer networks, also known as blockchains.
Let us define a smart contract, or simply contract, as a piece of code created by a blockchain user and executed by a blockchain node. A smart contract language (SCL) is a programming language that is either used to write a smart contract directly, or is compiled to it.
Programming languages differ on multiple dimensions, such as paradigm and type system. Due to a very unusual execution environment, SCLs have a different set of trade-offs compared to earlier languages. This spawned multiple attempts at creating secure and expressive SCLs.
Pre-Bitcoin
- A formal language for analyzing contracts - an essay by Nick Szabo
- E - referenced by Szabo
Bitcoin
- Bitcoin Script - a stack-based non Turing complete Forth-like language used to write script that determine whether a UTXO can be spent.
- Ivy - a non Turing complete higher-level language that compiles to Bitcoin Script (announcement)
- Simplicity - a typed functional programming language utilizing combinators blog post, another one
- BitML - a process calculus based language, compiles to Bitcoin script
Ethereum
- Ethereum bytecode - a Turing complete stack-based language executed by the Ethereum virtual machine (EVM)
- Solidity - a high-level imperative statically typed language compiled to EVM (docs)
- LLL - a "low-level Lisp-like language" compiled to EVM bytecode (blog post, series of blog posts)
- Vyper - a high-level language compiled to EVM (announcement of formal tools from RV)
- Bamboo - a high-level "formal-verification-friendly" language compiled to EVM
- functional-solidity-language - pretty much self-descriptive :)
- eWASM - a restricted subset of WebAssembly for Ethereum contracts
- Serpent - a Python-like high-level language compiled to EVM (deprecated due to security issues with the compiler)
- Mutan - a C-like language compiled to EVM (deprecated)
- Idris - a pure functional language with dependent types; Pettersson and Edström used it to write contracts that compile to EVM via Serpent
- Yul (ex JULIA, ex IULIA) - an intermediate low-level language (blog post)
- Babbage - "a mechanical smart contract language"
- Pyramid - An EVM backend for SICP Scheme
- L4 - a language "based on deontic modal logic", presented at Devcon 2 (Sep 2016)
- SolidityX - a typed-superset of Solidity
- Flint
- Lolisa (subset of Solidity)
- Formality - an efficient programming language featuring formal proofs
- Logikon - an experimental language for smart contracts
- Huff - an efficient low-level language with macros
DSLs
- Findel - a non Turing complete financial DSL inspired by a S.P.Jones' work
- the language from the paper by Egelund-Müller et al
- Chorus - a financial contractual markup language by Firmo network
- ADICO - a domain-specific language to support the contract modeling process
Other blockchains
- Michelson - a stack based and strongly typed domain-specific language (Tezos)
- Liquidity - a high-level typed smart-contract language that strictly complies to Michelson security restrictions (Tezos)
- fi (Tezos)
- Plutus - a pure functional language with user-defined data types and polymorphism (Cardano); compiles to Plutus Core (video)
- Marlowe (Cardano)
- Rholang - a reflective higher-order process calculus language (RChain)
- Obsidian - a state-oriented language with linear types
- DAML
- Simvolio (Apla blockchain platform)
- RIDE - a non Turing complete language infulenced by Scala and F# (Waves)
- Scilla - an intermediate level language for verified smart contracts (Zilliqa)
- TxVM (Chain)
- IELE
- Pact (Kadena)
- Ledger Design Language - a modeling language for describing public ledgers
- Sigma-State (Ergo)
- Sophia - a strongly typed language in the ML family (Æternity)
- Varna - a non Turing complete high-level language (Æternity)
- Rholang - a concurrent programming language, with a focus on message-passing and formally modeled by the ρ-calculus (RChain)
Other links
- https://github.com/pirapira/fp-ethereum - a collection of links related to function programming for Ethereum
- Smart Contract Languages Development to Follow - a post by Matt Suiche, Comae (Dec 2017)