provide a short-cut version for this macro in case

Tue Feb  3 21:24:01 2004  Tim Janik  <timj@gtk.org>

        * gtype.h (_G_TYPE_CVH): provide a short-cut version for
        this macro in case value->g_type==checked_type for gcc, similar
        to instance and class check short-cuts. this speeds up code that
        makes frequent use of G_VALUE_HOLDS_*() (e.g. setters/getters).

        * gtype.c (type_data_last_unref_Wm): don't call class-cache functions
        for the uncached case, this rendered g_type_class_unref_uncached()
        useless. pointed out by Stefan Westerfeld.
This commit is contained in:
Tim Janik
2004-02-03 20:30:23 +00:00
committed by Tim Janik
parent 341956610c
commit 999a87a19a
5 changed files with 34 additions and 5 deletions

View File

@@ -2009,8 +2009,9 @@ type_data_last_unref_Wm (GType type,
type_descriptive_name_I (type));
return;
}
if (node->is_classed && node->data && node->data->class.class && static_n_class_cache_funcs)
/* call class cache hooks */
if (node->is_classed && node->data && node->data->class.class && static_n_class_cache_funcs && !uncached)
{
guint i;