Skip to content

Commit

Permalink
fixup! feat: basic symbol table
Browse files Browse the repository at this point in the history
  • Loading branch information
mhanberg committed Jun 25, 2023
1 parent 87be90c commit 5fdeec2
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions lib/next_ls.ex
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,15 @@ defmodule NextLS do
extension_registry = Keyword.fetch!(args, :extension_registry)
extensions = Keyword.get(args, :extensions, [NextLS.ElixirExtension])
cache = Keyword.fetch!(args, :cache)
symbol_table = Keyword.fetch!(args, :symbol_table)

{:ok,
assign(lsp,
exit_code: 1,
documents: %{},
refresh_refs: %{},
cache: cache,
symbol_table: symbol_table,
task_supervisor: task_supervisor,
dynamic_supervisor: dynamic_supervisor,
extension_registry: extension_registry,
Expand Down
2 changes: 1 addition & 1 deletion test/next_ls/symbol_table_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ defmodule NextLS.SymbolTableTest do
assert :sys.get_state(pid).table == :symbol_table
end

test "builds the symbol table", %{dir: dir, pid: pid} do
test "builds the symbol table", %{pid: pid} do
symbols = symbols()

SymbolTable.put_symbols(pid, symbols)
Expand Down
2 changes: 1 addition & 1 deletion test/next_ls_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ defmodule NextLSTest do
start_supervised!({Registry, [keys: :unique, name: Registry.NextLSTest]})
extensions = [NextLS.ElixirExtension]
cache = start_supervised!(NextLS.DiagnosticCache)
symbol_table = start_supervised!(NextLS.SymbolTable)
symbol_table = start_supervised!({NextLS.SymbolTable, [path: tmp_dir]})

server =
server(NextLS,
Expand Down

0 comments on commit 5fdeec2

Please sign in to comment.