Get the latest tech news

Traits are a local maximum


An expose on Implicits and Local Coherence

Having the freedom to pick any trait implementation allows type checkers and optimizers to frolic across your code with reckless abandon. To skip a lot of detail, unstable implicits mean that our program might behave differently depending on how we infer types or inline terms. A big goal of local implicits is to solve the orphan instance problem and allow multiple implementations for a trait and type.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Rust traits

Rust traits

Photo of local maxima

local maxima

Photo of maxima

maxima