Cleaned up LSP types, add InitializeResult, no longer use a hardcoded string

This commit is contained in:
Alexandros Naskos
2020-11-06 10:08:20 +02:00
parent 996deb45fe
commit f7eff6632e
6 changed files with 307 additions and 230 deletions

View File

@@ -29,7 +29,7 @@ pub fn getDocComments(
allocator: *std.mem.Allocator,
tree: *ast.Tree,
node: *ast.Node,
format: types.MarkupKind,
format: types.MarkupContent.Kind,
) !?[]const u8 {
if (getDocCommentNode(tree, node)) |doc_comment_node| {
return try collectDocComments(allocator, tree, doc_comment_node, format);
@@ -41,7 +41,7 @@ pub fn collectDocComments(
allocator: *std.mem.Allocator,
tree: *ast.Tree,
doc_comments: *ast.Node.DocComment,
format: types.MarkupKind,
format: types.MarkupContent.Kind,
) ![]const u8 {
var lines = std.ArrayList([]const u8).init(allocator);
defer lines.deinit();