From c2db6c91df46d3f93c4c18a416d9c0d764ebd06a Mon Sep 17 00:00:00 2001 From: Dmitry Biletskyy Date: Fri, 15 Sep 2023 18:31:21 +0300 Subject: [PATCH] fix error get_attribute_reference_name never nil --- lib/next_ls/ast_helpers.ex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/next_ls/ast_helpers.ex b/lib/next_ls/ast_helpers.ex index c1d97b53..7c0d1079 100644 --- a/lib/next_ls/ast_helpers.ex +++ b/lib/next_ls/ast_helpers.ex @@ -7,11 +7,11 @@ defmodule NextLS.ASTHelpers do {_ast, name} = Macro.prewalk(ast, nil, fn - {:@, [line: ^line, column: ^column], [{name, _meta, nil}]} = ast, _acc -> {ast, name} + {:@, [line: ^line, column: ^column], [{name, _meta, nil}]} = ast, _acc -> {ast, "@#{name}"} other, acc -> {other, acc} end) - "@#{name}" + name end @spec get_module_attributes(String.t(), module()) :: [{atom(), String.t(), integer(), integer()}]