- */
+#ifndef TM_CTAGS_WRAPPERS +#define TM_CTAGS_WRAPPERS
+#include <glib.h>
+#include "tm_parser.h"
+#include "entry.h" /* for sTagEntryInfo */
+G_BEGIN_DECLS
+typedef gboolean (*tm_ctags_callback) (const tagEntryInfo *const tag,
- gboolean invalidate, void *user_data);
It also seems to have a strange signature only targeted at our very specific usage, although it suggest it's meant to be a generic API. By that I mean the `invalidate` parameter, that seem more like a step indicator that might be better served as an enum, or at least rather name it something like "initialize" or something more generic.
But maybe ```C typedef enum TMCtagsParsingStep { TM_CTAGS_PARSING_STEP_INITIALIZE, TM_CTAGS_PARSING_STEP_EMIT_TAG, // ... possibly _FINALIZE too } ``` Or something. Or, if we can be sure `tag` is never `NULL` when emitting tags, rely only on this?
Also, documentation on this callback would be great :)
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/geany/geany/pull/957/files/103d2c535862ae2682022dcfd714c2...