This weekend I discovered, that somehow Elixir-LS in VSCode and Sublime Text stopped to support autocompletion. ElixirSense crashed because of unknown functions. The solution was to upgrade to Elixir 1.12.3 as suggested by this comment on GitHub.
During the upgrade, I decided to also upgrade Erlang and do a complete fresh installation of Erlang and Elixir on my M1 MacBook. Sadly, the tutorial I have been following before I have owned a M1 MacBook, didn't work any longer. Erlang didn't compile successfully because it was unable to find the wxmac and unixodbc libraries. I had to add some extra options to solve this.
I assume you have installed asdf already, but here is the full installation command I use after reading the Tutorial by Andres.
brew install asdf autoconf wxmac openssl fop coreutils \ automake libyaml readline libxslt libtool \ unixodbc unzip curl
Next you have to set some extra environment variables that tell kerl where to find wxmac and unixodbc, like suggested by this comment on GitHub.
export CFLAGS="-O2 -g -fno-stack-check" export KERL_CONFIGURE_OPTIONS="--disable-hipe --with-ssl=$(brew --prefix openssl) --with-wx-config=$(brew --prefix wxmac)/bin/wx-config --with-odbc=$(brew --prefix unixodbc)" export CPPFLAGS="-I$(brew --prefix unixodbc)/include" export LDFLAGS="-L$(brew --prefix unixodbc)/lib"
Now you are ready to install Erlang 24 and Elixir 1.12.3 using asdf.
asdf install erlang 24.0.6 asdf global erlang 24.0.6 asdf install elixir 1.12.3 asdf global elixir 1.12.3
With Elixir 1.12.3 autocompletion works again for me.
P.S.: Of course you can also wait for the update of the homebrew elixir package, but I prefer to manage my environments using asdf.