@techee commented on this pull request.


In src/tagmanager/tm_workspace.c:

> @@ -768,6 +871,16 @@ static gint sort_found_tags(gconstpointer a, gconstpointer b, gpointer user_data
 		return -1;
 	else if (t2->file == info->file && t1->file != info->file)
 		return 1;
+	else if (info->header_file &&
+			 t1->file == info->header_file && t2->file != info->header_file)

I'm not sure if I understand the question correctly but

t1->file == info->header_file && t2->file != info->header_file

says that when we have two tags, t1 and t2, and t1 comes from header_file and t2 does not come from this header file, then t1 should be sorted in front of t2. The initial check for info->header_file non-NULL value is there because for global tags t1->file will also be NULL and then this check would do a wrong thing.


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <geany/geany/pull/3269/review/1102831800@github.com>