> Erlang’s data structures are all immutable. T...
# functional
m
Erlang’s data structures are all immutable. This vastly simplifies (and speeds up) almost all known GC algos.
Also per-process garbage collection. Web servers like Cowboy will spawn a separate erlang process for each request and then it will terminate after sending the response. If one process needs to GC, all others can continue running. Or best case, the process just dies before a full GC is ever run, and the whole process heap is reclaimed at once.