tri: exact matches are never ambiguous
Even when the exact match is a prefix of a longer match.
This commit is contained in:
@@ -113,6 +113,10 @@ void *tri_get_string_autocomplete(struct tri *tri, const char *string, bool *amb
|
|||||||
node = node->nodes[idx];
|
node = node->nodes[idx];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (node->value) {
|
||||||
|
return node->value;
|
||||||
|
}
|
||||||
|
|
||||||
while(1) {
|
while(1) {
|
||||||
struct tri_node *next_node = NULL;
|
struct tri_node *next_node = NULL;
|
||||||
int num_paths = 0;
|
int num_paths = 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user