Elixir 有垃圾收集器吗?

Does Elixir have a garbage collector?

我已经开始阅读 Elixir 编程语言。

我了解到:

  1. 功能正常
  2. 它是动态的但支持@spec
  3. 基于Erlang VM

我的问题是:它有某种 GC 吗?

是的,Erlang 有 GC,而且由于 Elixir 是基于 Erlang 构建的,所以它也有 GC。看到这个旧的 SO answer about Erlang GC and this 之一。 Elixir 站点引用 GC 如下:

Due to their lightweight nature, it is not uncommon to have hundreds of thousands of processes running concurrently in the same machine. Isolation allows processes to be garbage collected independently, reducing system-wide pauses, and using all machine resources as efficiently as possible (vertical scaling).