was founded on the core notion that code is immutable and identified by its content. Now in a public alpha release, with multiple milestone alpha releases planned, Unison is due for a production release this year.
Unison is designed to offer special support for building distributed systems. Motivating Unison is the idea that technology for building software should be thoughtfully crafted in all aspects. Complexities are to be stripped away. The core developers of the language started Unison as a research project where they would be willing to rethink how programming works, one of the core developers, Paul Chiusano, said.
Still in an experimental stage, Unison is a statically typed functional programming language similar to Haskell that offers the following capabilities:
- The ability to describe distributed systems
- Simplified codebase management
- Trivial renaming
Definitions in Unison are identified by content, with each definition constituting a syntax tree. By hashing the tree in a way that incorporates hashes of the definition’s dependencies, the Unison hash uniquely identifies that definition. This feature is intended to serve as the basis for serious improvements to the programming experience, eliminating builds and most dependency conflicts and allowing for easy deployment of code and typed durable storage.
For refactoring, Unison offers a structured process in which a new, compiling version of the code is built up incrementally off to the side, providing benefits such as a codebase that is always runnable and never broken, eliminating the need to upgrade an entire codebase.
Remote.Transfer function in the language provides a “remote effect” that facilitates computation on multiple Unison nodes. Dynamic transfer of arbitrary computations is doable because definitions in Unison are identified through a cryptographic hash of their content. When computations are transferred, the recipient node checks to see if the content references any unknown hashes. Unknown hashes are synced to the recipient before the transfer completes and the computation proceeds.