$ the-wire · showcase
Elixir prunes BDD-to-DNF expansion before it explodes
By RepoJournal · Filed · About Elixir & Phoenix · Composed from the cited sources · methodology
The type checker now intersects positive literals while expanding map and tuple BDDs instead of after, cutting one defguard case from 100,834 generated lines to the 3,764 that survived anyway.
Prune disjoint positives when converting map and tuple BDDs to DNF elixir-lang/elixir
Converting a map or tuple BDD to DNF used to expand every path and only then intersect each line's positive literals, discarding the empty results; the positives are now intersected as the conversion proceeds. In the "from multiple defguard" test, 116 map key fetches expanded 100,834 lines of which just 3,764 were non-empty, so the wasted work is the bulk of the cost when a struct union is refi...
Prune disjoint positives when converting map and tuple BDDs to DNF (#16046) elixir-lang/elixir
The commit that lands the pruning in elixir-lang/elixir. This is type checker internals, not a language change: nothing in your code's semantics moves, but analysis time on heavily union-typed map and tuple code does.
Occurrence typing for cond and with elixir-lang/elixir
Occurrence typing extends to `cond` and `with`, so narrowing from a clause's test can flow into the branches that follow it rather than stopping at pattern matches alone. Code that branches on type checks inside `cond` or digs through `with` clauses stands to get more precise analysis without annotation.