Thread-safety annotation needed
Submitted by Mikhail Zabaluev
Most of the introspected object types cannot assumed to be thread-safe, but there are some important exceptions, such as GMainContext and GMainLoop, some types in GStreamer.
For languages where thread safety can be utilized at the language level, an annotation would be helpful to generate bindings for such types accordingly.
So far the only language known to me where this is important is Rust, though Haskell people might consider this interesting as well. In my nascent Rust bindings (https://github.com/mzabaluev/grust), I have resorted to defining wrappers for the introspected types as unsafe for being passed or shared between tasks by default, and relaxing that restriction on a case-by-case basis, which will require some solution for whitelisting.
P.S. In Gio, there is GCancellable which is peculiar: its own methods are thread-safe, but the GObject it derives from is not.