VariantDict.clear

void clear()

Releases all memory associated with a #GVariantDict without freeing the #GVariantDict structure itself.

It typically only makes sense to do this on a stack-allocated #GVariantDict if you want to abort building the value part-way through. This function need not be called if you call [glib.variant_dict.VariantDict.end] and it also doesn't need to be called on dicts allocated with g_variant_dict_new (see [glib.variant_dict.VariantDict.unref] for that).

It is valid to call this function on either an initialised #GVariantDict or one that was previously cleared by an earlier call to [glib.variant_dict.VariantDict.clear] but it is not valid to call this function on uninitialised memory.