Skip to content

Commit 3d337ae

Browse files
authored
Include all core Elixir apps in PLT (#225)
1 parent ff1103c commit 3d337ae

File tree

1 file changed

+10
-6
lines changed
  • apps/language_server/lib/language_server/dialyzer

1 file changed

+10
-6
lines changed

apps/language_server/lib/language_server/dialyzer/manifest.ex

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -114,19 +114,23 @@ defmodule ElixirLS.LanguageServer.Dialyzer.Manifest do
114114
Path.join([Mix.Utils.mix_home(), "elixir-ls-#{otp_vsn()}_elixir-#{System.version()}"])
115115
end
116116

117+
@elixir_apps [:elixir, :eex, :ex_unit, :iex, :logger, :mix]
118+
117119
defp build_elixir_plt() do
118120
JsonRpc.show_message(
119121
:info,
120122
"Building core Dialyzer Elixir PLT. This will take a few minutes (often 15+) and can be disabled in the settings."
121123
)
122124

123125
files =
124-
Path.join([Application.app_dir(:elixir), "**/*.beam"])
125-
|> Path.wildcard()
126-
|> Enum.map(&pathname_to_module/1)
127-
|> expand_references()
128-
|> Enum.map(&Utils.get_beam_file/1)
129-
|> Enum.filter(&is_list/1)
126+
Enum.flat_map(@elixir_apps, fn app ->
127+
Path.join([Application.app_dir(app), "**/*.beam"])
128+
|> Path.wildcard()
129+
|> Enum.map(&pathname_to_module/1)
130+
|> expand_references()
131+
|> Enum.map(&Utils.get_beam_file/1)
132+
|> Enum.filter(&is_list/1)
133+
end)
130134

131135
File.mkdir_p!(Path.dirname(elixir_plt_path()))
132136

0 commit comments

Comments
 (0)