aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel Gavin <danielgavin5@hotmail.com>2021-12-31 16:01:22 +0100
committerDaniel Gavin <danielgavin5@hotmail.com>2021-12-31 16:01:22 +0100
commitf611ad25a431d8b15bf826effdefb80d9e874d8a (patch)
treeb31687750c1607edbc6c6f975db7471d8acacd60 /src
parentd28b0ac8400136d0ccc6942c907e6fb3f034488f (diff)
refractor
Diffstat (limited to 'src')
-rw-r--r--src/analysis/analysis.odin52
-rw-r--r--src/index/collector.odin31
-rw-r--r--src/index/symbol.odin20
-rw-r--r--src/server/completion.odin132
-rw-r--r--src/server/hover.odin2
-rw-r--r--src/server/signature.odin4
6 files changed, 145 insertions, 96 deletions
diff --git a/src/analysis/analysis.odin b/src/analysis/analysis.odin
index 1330796..f80e1d0 100644
--- a/src/analysis/analysis.odin
+++ b/src/analysis/analysis.odin
@@ -1704,6 +1704,7 @@ make_symbol_union_from_ast :: proc(ast_context: ^AstContext, v: ast.Union_Type,
range = common.get_token_range(v, ast_context.file.src),
type = .Union,
pkg = get_package_from_node(v.node),
+ name = ident,
};
if inlined {
@@ -1727,7 +1728,6 @@ make_symbol_union_from_ast :: proc(ast_context: ^AstContext, v: ast.Union_Type,
symbol.value = index.SymbolUnionValue {
types = v.variants,
- union_name = ident,
};
if v.poly_params != nil {
@@ -1741,6 +1741,7 @@ make_symbol_enum_from_ast :: proc(ast_context: ^AstContext, v: ast.Enum_Type, id
symbol := index.Symbol {
range = common.get_token_range(v, ast_context.file.src),
type = .Enum,
+ name = ident,
pkg = get_package_from_node(v.node),
};
@@ -1766,7 +1767,6 @@ make_symbol_enum_from_ast :: proc(ast_context: ^AstContext, v: ast.Enum_Type, id
symbol.value = index.SymbolEnumValue {
names = names[:],
- enum_name = ident,
};
return symbol;
@@ -1777,6 +1777,7 @@ make_symbol_bitset_from_ast :: proc(ast_context: ^AstContext, v: ast.Bit_Set_Typ
symbol := index.Symbol {
range = common.get_token_range(v, ast_context.file.src),
type = .Enum,
+ name = ident,
pkg = get_package_from_node(v.node),
};
@@ -1787,7 +1788,6 @@ make_symbol_bitset_from_ast :: proc(ast_context: ^AstContext, v: ast.Bit_Set_Typ
symbol.value = index.SymbolBitSetValue {
expr = v.elem,
- bitset_name = ident,
};
return symbol;
@@ -1799,6 +1799,7 @@ make_symbol_struct_from_ast :: proc(ast_context: ^AstContext, v: ast.Struct_Type
range = common.get_token_range(v, ast_context.file.src),
type = .Struct,
pkg = get_package_from_node(v.node),
+ name = ident,
};
if inlined {
@@ -1827,7 +1828,6 @@ make_symbol_struct_from_ast :: proc(ast_context: ^AstContext, v: ast.Struct_Type
names = names[:],
types = types[:],
usings = usings,
- struct_name = ident,
};
if v.poly_params != nil {
@@ -2400,6 +2400,7 @@ clear_locals :: proc(ast_context: ^AstContext) {
clear(&ast_context.usings);
}
+/*
resolve_entire_file :: proc(document: ^common.Document, allocator := context.allocator) -> []^index.Symbol {
ast_context := make_ast_context(document.ast, document.imports, document.package_name, document.uri.uri);
@@ -2426,25 +2427,35 @@ resolve_entire_procedure :: proc(procedure: ^ast.Proc_Type, symbols: ^[]^index.S
}
+*/
-concatenate_symbols_information :: proc(ast_context: ^AstContext, symbol: index.Symbol, is_completion: bool) -> string {
- pkg := path.base(symbol.pkg, false, context.temp_allocator);
+concatenate_symbol_information :: proc {
+ concatenate_raw_symbol_information,
+ concatenate_raw_string_information,
+}
- if symbol.type == .Function {
- if symbol.returns != "" {
- return fmt.tprintf("%v.%v: proc%v -> %v", pkg, symbol.name, symbol.signature, symbol.returns);
+concatenate_raw_symbol_information :: proc(ast_context: ^AstContext, symbol: index.Symbol, is_completion: bool) -> string {
+ return concatenate_raw_string_information(ast_context, symbol.pkg, symbol.name, symbol.signature, symbol.returns, symbol.type, is_completion);
+}
+
+concatenate_raw_string_information :: proc(ast_context: ^AstContext, pkg: string, name: string, signature: string, returns: string, type: index.SymbolType, is_completion: bool) -> string {
+ pkg := path.base(pkg, false, context.temp_allocator);
+
+ if type == .Function {
+ if returns != "" {
+ return fmt.tprintf("%v.%v: proc%v -> %v", pkg, name, signature, returns);
} else {
- return fmt.tprintf("%v.%v: proc%v", pkg, symbol.name, symbol.signature);
+ return fmt.tprintf("%v.%v: proc%v", pkg, name, signature);
}
- } else if symbol.type == .Package {
- return symbol.name;
- } else if symbol.type == .Keyword && is_completion {
- return symbol.name;
+ } else if type == .Package {
+ return name;
+ } else if type == .Keyword && is_completion {
+ return name;
} else {
- if symbol.signature != "" {
- return fmt.tprintf("%v.%v: %v", pkg, symbol.name, symbol.signature);
+ if signature != "" {
+ return fmt.tprintf("%v.%v: %v", pkg, name, signature);
} else {
- return fmt.tprintf("%v.%v", pkg, symbol.name);
+ return fmt.tprintf("%v.%v", pkg, name);
}
}
}
@@ -2468,7 +2479,6 @@ unwrap_enum :: proc(ast_context: ^AstContext, node: ^ast.Expr) -> (index.SymbolE
unwrap_union :: proc(ast_context: ^AstContext, node: ^ast.Expr) -> (index.SymbolUnionValue, bool) {
if union_symbol, ok := resolve_type_expression(ast_context, node); ok {
-
if union_value, ok := union_symbol.value.(index.SymbolUnionValue); ok {
return union_value, true;
}
@@ -2511,7 +2521,7 @@ get_signature :: proc(ast_context: ^AstContext, ident: ast.Ident, symbol: index.
return common.node_to_string(v.expr);
case SymbolEnumValue:
if is_variable {
- return v.enum_name;
+ return symbol.name;
}
else {
return "enum";
@@ -2522,14 +2532,14 @@ get_signature :: proc(ast_context: ^AstContext, ident: ast.Ident, symbol: index.
return "proc";
case SymbolStructValue:
if is_variable {
- return v.struct_name;
+ return symbol.name;
}
else {
return "struct";
}
case SymbolUnionValue:
if is_variable {
- return v.union_name;
+ return symbol.name;
}
else {
return "union";
diff --git a/src/index/collector.odin b/src/index/collector.odin
index 077f6ee..a76fef5 100644
--- a/src/index/collector.odin
+++ b/src/index/collector.odin
@@ -62,7 +62,6 @@ delete_symbol_collection :: proc(collection: SymbolCollection) {
}
collect_procedure_fields :: proc(collection: ^SymbolCollection, proc_type: ^ast.Proc_Type, arg_list: ^ast.Field_List, return_list: ^ast.Field_List, package_map: map[string]string) -> SymbolProcedureValue {
-
returns := make([dynamic]^ast.Field, 0, collection.allocator);
args := make([dynamic]^ast.Field, 0, collection.allocator);
@@ -92,8 +91,7 @@ collect_procedure_fields :: proc(collection: ^SymbolCollection, proc_type: ^ast.
return value;
}
-collect_struct_fields :: proc(collection: ^SymbolCollection, struct_type: ast.Struct_Type, package_map: map[string]string, ident: string) -> SymbolStructValue {
-
+collect_struct_fields :: proc(collection: ^SymbolCollection, struct_type: ast.Struct_Type, package_map: map[string]string) -> SymbolStructValue {
names := make([dynamic]string, 0, collection.allocator);
types := make([dynamic]^ast.Expr, 0, collection.allocator);
usings := make(map[string]bool, 0, collection.allocator);
@@ -118,15 +116,13 @@ collect_struct_fields :: proc(collection: ^SymbolCollection, struct_type: ast.St
names = names[:],
types = types[:],
usings = usings,
- struct_name = get_index_unique_string(collection, ident),
poly = cast(^ast.Field_List)clone_type(struct_type.poly_params, collection.allocator, &collection.unique_strings),
};
return value;
}
-collect_enum_fields :: proc(collection: ^SymbolCollection, fields: []^ast.Expr, package_map: map[string]string, ident: string) -> SymbolEnumValue {
-
+collect_enum_fields :: proc(collection: ^SymbolCollection, fields: []^ast.Expr, package_map: map[string]string) -> SymbolEnumValue {
names := make([dynamic]string, 0, collection.allocator);
//ERROR no hover on n in the for, but elsewhere is fine
@@ -144,14 +140,12 @@ collect_enum_fields :: proc(collection: ^SymbolCollection, fields: []^ast.Expr,
value := SymbolEnumValue {
names = names[:],
- enum_name = get_index_unique_string(collection, ident),
};
return value;
}
-collect_union_fields :: proc(collection: ^SymbolCollection, union_type: ast.Union_Type, package_map: map[string]string, ident: string) -> SymbolUnionValue {
-
+collect_union_fields :: proc(collection: ^SymbolCollection, union_type: ast.Union_Type, package_map: map[string]string) -> SymbolUnionValue {
types := make([dynamic]^ast.Expr, 0, collection.allocator);
for variant in union_type.variants {
@@ -162,26 +156,22 @@ collect_union_fields :: proc(collection: ^SymbolCollection, union_type: ast.Unio
value := SymbolUnionValue {
types = types[:],
- union_name = get_index_unique_string(collection, ident),
poly = cast(^ast.Field_List)clone_type(union_type.poly_params, collection.allocator, &collection.unique_strings),
};
return value;
}
-collect_bitset_field :: proc(collection: ^SymbolCollection, bitset_type: ast.Bit_Set_Type, package_map: map[string]string, ident: string) -> SymbolBitSetValue {
-
+collect_bitset_field :: proc(collection: ^SymbolCollection, bitset_type: ast.Bit_Set_Type, package_map: map[string]string) -> SymbolBitSetValue {
cloned := clone_type(bitset_type.elem, collection.allocator, &collection.unique_strings);
replace_package_alias(cloned, package_map, collection);
return SymbolBitSetValue {
expr = cloned,
- bitset_name = get_index_unique_string(collection, ident),
};
}
collect_slice :: proc(collection: ^SymbolCollection, array: ast.Array_Type, package_map: map[string]string) -> SymbolFixedArrayValue {
-
elem := clone_type(array.elem, collection.allocator, &collection.unique_strings);
len := clone_type(array.len, collection.allocator, &collection.unique_strings);
@@ -195,7 +185,6 @@ collect_slice :: proc(collection: ^SymbolCollection, array: ast.Array_Type, pack
}
collect_array :: proc(collection: ^SymbolCollection, array: ast.Array_Type, package_map: map[string]string) -> SymbolSliceValue {
-
elem := clone_type(array.elem, collection.allocator, &collection.unique_strings);
replace_package_alias(elem, package_map, collection);
@@ -206,7 +195,6 @@ collect_array :: proc(collection: ^SymbolCollection, array: ast.Array_Type, pack
}
collect_map :: proc(collection: ^SymbolCollection, m: ast.Map_Type, package_map: map[string]string) -> SymbolMapValue {
-
key := clone_type(m.key, collection.allocator, &collection.unique_strings);
value := clone_type(m.value, collection.allocator, &collection.unique_strings);
@@ -220,7 +208,6 @@ collect_map :: proc(collection: ^SymbolCollection, m: ast.Map_Type, package_map:
}
collect_dynamic_array :: proc(collection: ^SymbolCollection, array: ast.Dynamic_Array_Type, package_map: map[string]string) -> SymbolDynamicArrayValue {
-
elem := clone_type(array.elem, collection.allocator, &collection.unique_strings);
replace_package_alias(elem, package_map, collection);
@@ -231,7 +218,6 @@ collect_dynamic_array :: proc(collection: ^SymbolCollection, array: ast.Dynamic_
}
collect_generic :: proc(collection: ^SymbolCollection, expr: ^ast.Expr, package_map: map[string]string) -> SymbolGenericValue {
-
cloned := clone_type(expr, collection.allocator, &collection.unique_strings);
replace_package_alias(cloned, package_map, collection);
@@ -243,7 +229,6 @@ collect_generic :: proc(collection: ^SymbolCollection, expr: ^ast.Expr, package_
}
collect_symbols :: proc(collection: ^SymbolCollection, file: ast.File, uri: string) -> common.Error {
-
forward, _ := filepath.to_slash(file.fullpath, context.temp_allocator);
when ODIN_OS == "windows" {
@@ -300,22 +285,22 @@ collect_symbols :: proc(collection: ^SymbolCollection, file: ast.File, uri: stri
case ast.Struct_Type:
token = v;
token_type = .Struct;
- symbol.value = collect_struct_fields(collection, v, package_map, name);
+ symbol.value = collect_struct_fields(collection, v, package_map);
symbol.signature = "struct";
case ast.Enum_Type:
token = v;
token_type = .Enum;
- symbol.value = collect_enum_fields(collection, v.fields, package_map, name);
+ symbol.value = collect_enum_fields(collection, v.fields, package_map);
symbol.signature = "enum";
case ast.Union_Type:
token = v;
token_type = .Union;
- symbol.value = collect_union_fields(collection, v, package_map, name);
+ symbol.value = collect_union_fields(collection, v, package_map);
symbol.signature = "union";
case ast.Bit_Set_Type:
token = v;
token_type = .Enum;
- symbol.value = collect_bitset_field(collection, v, package_map, name);
+ symbol.value = collect_bitset_field(collection, v, package_map);
symbol.signature = "bitset";
case ast.Map_Type:
token = v;
diff --git a/src/index/symbol.odin b/src/index/symbol.odin
index 5001054..37392e4 100644
--- a/src/index/symbol.odin
+++ b/src/index/symbol.odin
@@ -11,7 +11,6 @@ import "core:slice"
import "shared:common"
SymbolStructValue :: struct {
- struct_name: string,
names: []string,
types: []^ast.Expr,
usings: map[string]bool,
@@ -36,12 +35,10 @@ SymbolAggregateValue :: struct {
}
SymbolEnumValue :: struct {
- enum_name: string,
names: []string,
}
SymbolUnionValue :: struct {
- union_name: string,
types: []^ast.Expr,
poly: ^ast.Field_List,
}
@@ -64,7 +61,6 @@ SymbolBasicValue :: struct {
}
SymbolBitSetValue :: struct {
- bitset_name: string,
expr: ^ast.Expr,
}
@@ -113,17 +109,17 @@ SymbolFlag :: enum {
SymbolFlags :: bit_set[SymbolFlag]
Symbol :: struct {
- range: common.Range,
- uri: string,
- pkg: string,
- name: string,
+ range: common.Range, //the range of the symbol in the file
+ uri: string, //uri of the file the symbol resides
+ pkg: string, //absolute directory path where the symbol resides
+ name: string, //name of the symbol
doc: string,
- signature: string,
- returns: string,
+ signature: string, //type signature
+ returns: string, //precedure return signature
type: SymbolType,
value: SymbolValue,
- references: []common.Location,
- pointers: int,
+ references: []common.Location, //all the places in the project that it's being referenced
+ pointers: int, //how many `^` are applied to the symbol
flags: SymbolFlags,
}
diff --git a/src/server/completion.odin b/src/server/completion.odin
index 38b3c34..87490ac 100644
--- a/src/server/completion.odin
+++ b/src/server/completion.odin
@@ -365,19 +365,19 @@ get_selector_completion :: proc(ast_context: ^analysis.AstContext, position_cont
for type in v.types {
if symbol, ok := resolve_type_expression(ast_context, type); ok {
base := path.base(symbol.pkg, false, context.temp_allocator);
- if symbol.pkg == ast_context.document_package || base == "runtime" {
- symbol.name = fmt.aprintf("(%v)", common.node_to_string(type));
- } else {
- symbol.name = fmt.aprintf("(%v.%v)", path.base(symbol.pkg, false, context.temp_allocator), common.node_to_string(type));
- }
item := CompletionItem {
- label = symbol.name,
kind = .EnumMember,
detail = fmt.tprintf("%v", selector.name),
documentation = symbol.doc,
};
+ if symbol.pkg == ast_context.document_package || base == "runtime" {
+ item.label = fmt.aprintf("(%v)", common.node_to_string(type));
+ } else {
+ item.label = fmt.aprintf("(%v.%v)", path.base(symbol.pkg, false, context.temp_allocator), common.node_to_string(type));
+ }
+
append(&items, item);
}
}
@@ -454,7 +454,7 @@ get_selector_completion :: proc(ast_context: ^analysis.AstContext, position_cont
item := CompletionItem {
label = symbol.name,
kind = cast(CompletionItemKind)symbol.type,
- detail = concatenate_symbols_information(ast_context, symbol, true),
+ detail = concatenate_symbol_information(ast_context, symbol, true),
documentation = symbol.doc,
};
@@ -823,11 +823,16 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
list.isIncomplete = true;
CombinedResult :: struct {
- score: f32,
- symbol: index.Symbol,
- variable: ^ast.Ident,
- snippet: Snippet_Info,
- name: string,
+ score: f32,
+ variable: ^ast.Ident,
+ snippet: Snippet_Info,
+ name: string,
+ type: index.SymbolType,
+ doc: string,
+ pkg: string,
+ signature: string,
+ returns: string,
+ flags: index.SymbolFlags,
};
combined_sort_interface :: proc(s: ^[dynamic]CombinedResult) -> sort.Interface {
@@ -875,7 +880,16 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
build_procedure_symbol_return(&r.symbol);
build_procedure_symbol_signature(&r.symbol);
if r.symbol.uri != ast_context.uri {
- append(&combined, CombinedResult {score = r.score, symbol = r.symbol});
+ append(&combined, CombinedResult {
+ score = r.score,
+ type = r.symbol.type,
+ name = r.symbol.name,
+ doc = r.symbol.doc,
+ flags = r.symbol.flags,
+ signature = r.symbol.signature,
+ returns = r.symbol.returns,
+ pkg = r.symbol.pkg,
+ });
}
}
}
@@ -889,7 +903,7 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
//combined is sorted and should do binary search instead.
for result in combined {
- if result.symbol.name == k {
+ if result.name == k {
continue global;
}
}
@@ -903,13 +917,22 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
if symbol, ok := resolve_type_identifier(ast_context, ident^); ok {
symbol.signature = get_signature(ast_context, ident^, symbol);
- symbol.name = ident.name;
build_procedure_symbol_return(&symbol);
build_procedure_symbol_signature(&symbol);
- if score, ok := common.fuzzy_match(matcher, symbol.name); ok == 1 {
- append(&combined, CombinedResult {score = score * 1.1, symbol = symbol, variable = ident});
+ if score, ok := common.fuzzy_match(matcher, ident.name); ok == 1 {
+ append(&combined, CombinedResult {
+ score = score * 1.1,
+ type = symbol.type,
+ name = ident.name,
+ doc = symbol.doc,
+ flags = symbol.flags,
+ pkg = symbol.pkg,
+ signature = symbol.signature,
+ returns = symbol.returns,
+ variable = ident,
+ });
}
}
}
@@ -919,23 +942,31 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
break;
}
- ast_context.use_locals = true;
- ast_context.use_globals = true;
+ ast_context.use_locals = true;
+ ast_context.use_globals = true;
ast_context.current_package = ast_context.document_package;
ident := index.new_type(ast.Ident, {offset = position_context.position}, {offset = position_context.position}, context.temp_allocator);
ident.name = k;
- if symbol, ok := resolve_type_identifier(ast_context, ident^); ok {
-
+ if symbol, ok := resolve_type_identifier(ast_context, ident^); ok {
symbol.signature = get_signature(ast_context, ident^, symbol);
- symbol.name = ident.name;
build_procedure_symbol_return(&symbol);
build_procedure_symbol_signature(&symbol);
- if score, ok := common.fuzzy_match(matcher, symbol.name); ok == 1 {
- append(&combined, CombinedResult {score = score * 1.1, symbol = symbol, variable = ident});
+ if score, ok := common.fuzzy_match(matcher, ident.name); ok == 1 {
+ append(&combined, CombinedResult {
+ score = score * 1.1,
+ type = symbol.type,
+ name = ident.name,
+ doc = symbol.doc,
+ flags = symbol.flags,
+ pkg = symbol.pkg,
+ signature = symbol.signature,
+ returns = symbol.returns,
+ variable = ident,
+ });
}
}
}
@@ -951,7 +982,16 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
};
if score, ok := common.fuzzy_match(matcher, symbol.name); ok == 1 {
- append(&combined, CombinedResult {score = score * 1.1, symbol = symbol});
+ append(&combined, CombinedResult {
+ score = score * 1.1,
+ type = symbol.type,
+ name = symbol.name,
+ doc = symbol.doc,
+ flags = symbol.flags,
+ signature = symbol.signature,
+ returns = symbol.returns,
+ pkg = symbol.pkg,
+ });
}
}
@@ -962,7 +1002,16 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
};
if score, ok := common.fuzzy_match(matcher, keyword); ok == 1 {
- append(&combined, CombinedResult {score = score * 1.1, symbol = symbol});
+ append(&combined, CombinedResult {
+ score = score * 1.1,
+ type = symbol.type,
+ name = symbol.name,
+ doc = symbol.doc,
+ flags = symbol.flags,
+ signature = symbol.signature,
+ returns = symbol.returns,
+ pkg = symbol.pkg,
+ });
}
}
@@ -973,7 +1022,16 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
};
if score, ok := common.fuzzy_match(matcher, keyword); ok == 1 {
- append(&combined, CombinedResult {score = score * 1.1, symbol = symbol});
+ append(&combined, CombinedResult {
+ score = score * 1.1,
+ type = symbol.type,
+ name = symbol.name,
+ doc = symbol.doc,
+ flags = symbol.flags,
+ signature = symbol.signature,
+ returns = symbol.returns,
+ pkg = symbol.pkg,
+ });
}
}
@@ -994,8 +1052,8 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
result := result;
- //Skip procedures when the position is in proc decl
- if position_in_proc_decl(position_context) && result.symbol.type == .Function && common.config.enable_procedure_context {
+ //Skip procedures when the position is in proc decl
+ if position_in_proc_decl(position_context) && result.type == .Function && common.config.enable_procedure_context {
continue;
}
@@ -1022,30 +1080,30 @@ get_identifier_completion :: proc(ast_context: ^analysis.AstContext, position_co
append(&items, item);
} else {
item := CompletionItem {
- label = result.symbol.name,
+ label = result.name,
insertTextFormat = .PlainText,
- documentation = result.symbol.doc,
+ documentation = result.doc,
};
if result.variable != nil {
if ok := resolve_ident_is_variable(ast_context, result.variable^); ok {
item.kind = .Variable;
- result.symbol.type = .Variable;
+ result.type = .Variable;
} else {
- item.kind = cast(CompletionItemKind)result.symbol.type;
+ item.kind = cast(CompletionItemKind)result.type;
}
} else {
- item.kind = cast(CompletionItemKind)result.symbol.type;
+ item.kind = cast(CompletionItemKind)result.type;
}
- if result.symbol.type == .Function {
+ if result.type == .Function {
item.insertText = fmt.tprintf("%v($0)", item.label);
item.insertTextFormat = .Snippet;
- item.deprecated = .Deprecated in result.symbol.flags;
+ item.deprecated = .Deprecated in result.flags;
item.command.command = "editor.action.triggerParameterHints";
}
- item.detail = concatenate_symbols_information(ast_context, result.symbol, true);
+ item.detail = concatenate_symbol_information(ast_context, result.pkg, result.name, result.signature, result.returns, result.type, true);
append(&items, item);
}
diff --git a/src/server/hover.odin b/src/server/hover.odin
index e3e08fa..123dc49 100644
--- a/src/server/hover.odin
+++ b/src/server/hover.odin
@@ -37,7 +37,7 @@ write_hover_content :: proc(ast_context: ^analysis.AstContext, symbol: index.Sym
build_procedure_symbol_return(&symbol);
build_procedure_symbol_signature(&symbol);
- cat := concatenate_symbols_information(ast_context, symbol, false);
+ cat := concatenate_symbol_information(ast_context, symbol, false);
if cat != "" {
content.kind = "markdown";
diff --git a/src/server/signature.odin b/src/server/signature.odin
index 1e89dc1..d7fe289 100644
--- a/src/server/signature.odin
+++ b/src/server/signature.odin
@@ -178,7 +178,7 @@ get_signature_information :: proc(document: ^common.Document, position: common.P
build_procedure_symbol_return(&call);
info := SignatureInformation {
- label = concatenate_symbols_information(&ast_context, call, false),
+ label = concatenate_symbol_information(&ast_context, call, false),
documentation = call.doc,
parameters = parameters,
};
@@ -209,7 +209,7 @@ get_signature_information :: proc(document: ^common.Document, position: common.P
build_procedure_symbol_return(&symbol);
info := SignatureInformation {
- label = concatenate_symbols_information(&ast_context, symbol, false),
+ label = concatenate_symbol_information(&ast_context, symbol, false),
documentation = symbol.doc,
parameters = parameters,
};