What else can we do with type systems?

Recently I learned that the lifetimes and borrow checkers in Rust are implemented using its type systems. Details here: https://doc.rust-lang.org/nomicon/subtyping.html

It makes me wonder what else we can do using a type system. For example, purity as part of the type of a function, which means all its side effects must be (explicitly or implicitly) declared. Actually, some people have already been working on it: the Koka programming language.

Licensed under CC BY-NC-SA 4.0
comments powered by Disqus
196884 = 196883 + 1
Built with Hugo
Theme Stack designed by Jimmy