summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ide-definitions.c8
-rw-r--r--main.c1
2 files changed, 8 insertions, 1 deletions
diff --git a/ide-definitions.c b/ide-definitions.c
index 7175e08..185a270 100644
--- a/ide-definitions.c
+++ b/ide-definitions.c
@@ -113,7 +113,13 @@ static int definition_entry_qsort_cmp(const void *av, const void *bv) {
if (a_len < b_len) return -1;
if (a_len > b_len) return 1;
// then sort alphabetically
- return strcmp(a->name, b->name);
+ int cmp = strcmp(a->name, b->name);
+ if (cmp) return cmp;
+ // then sort by detail
+ if (!a->detail && b->detail) return -1;
+ if (a->detail && !b->detail) return 1;
+ if (!a->detail && !b->detail) return 0;
+ return strcmp(a->detail, b->detail);
}
// put the entries matching the search term into the selector.
diff --git a/main.c b/main.c
index a49e6dd..31866f2 100644
--- a/main.c
+++ b/main.c
@@ -2,6 +2,7 @@
@TODO:
- fix problem where LSP_REQUEST_DEFINITION tag isn't being found
- ted.h documentation
+- don't start up separate clangd servers for C and C++
- handle multiple symbols with same name in go-to-definition menu
- better non-error window/showMessage(Request)
- document lsp.h and lsp.c.