Skip to content

girepository: Also store GType cache misses

Carlos Garnacho requested to merge wip/carlosg/cache-misses into master

There are notably 3 classes of GTypes where a girepository lookup might fail:

  • GTypes from private interfaces in public objects (eg. MetaCullable in mutter)
  • GTypes for private base objects with public interfaces (eg. GLocalFile in GLib)
  • GTypes registered from the language, and presumably not coming from the GIR

It is moot to look for those over and over again, and a full lookup can be taxing if looking up for a method/property on objects with those characteristics.

It seems we can cache the misses too, so next lookups are just as quick as an introspected GType.

Merge request reports