Skip to content

Conversation

@Munksgaard
Copy link

This PR fixes a crash that happens if Elixir has been built with the ERL_COMPILER_OPTIONS=deterministic compiler flag. That flag causes the build to strip out the source tag from the compilation info of stdlib modules.

When finding the Elixir sources, we elixir-ls would crash because enum_ex_path is nil when the source tag isn't set and File.exists?/2 does not support nil as its first argument.

This PR relaxes the constraint by first checking whether enum_ex_path is nil, in which case a different log message is printed before returning false.

Fixes #1197

This PR fixes a crash that happens if Elixir has been built with the `ERL_COMPILER_OPTIONS=deterministic` compiler flag. That flag causes the build to strip out the source tag from the compilation info of stdlib modules. When finding the Elixir sources, we elixir-ls would crash because `enum_ex_path` is nil when the source tag isn't set and `File.exists?/2` does not support nil as its first argument. This PR relaxes the constraint by first checking whether `enum_ex_path` is nil, in which case a different log message is printed before returning false. Fixes elixir-lsp#1197
@Munksgaard
Copy link
Author

Closed in favor of #1216

@Munksgaard Munksgaard closed this Jul 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant