Another way of approaching this would be to require clients calling back into gjs for information from e.g. a `GjsInterruptCallback`. Then the callback would have an opaque parameter (let's call it `GjsCallbackInfo` or something) with no exposed fields, and APIs like `gjs_interrupt_register_get_interrupt_info (GjsInterruptRegister *, GjsCallbackInfo *, out const guint * line, out const gchar ** function_name);`
That way memory management is more explicit, and you have less public API overall. Something worth considering.