DeprecatedconstructorStaticDeprecatedheightReturns the height of a GLib.TrashStack.
Note that execution of this function is of O(N) complexity where N denotes the number of items on the stack.
Deprecatedstack_p: TrashStackStaticDeprecatedpeekReturns the element at the top of a GLib.TrashStack
which may be null.
Deprecatedstack_p: TrashStackStaticDeprecatedpopStaticDeprecatedpushPushes a piece of memory onto a GLib.TrashStack.
Deprecatedstack_p: TrashStackDeprecateddata_p: anythe piece of memory to push on the stack
A GLib.TrashStack is an efficient way to keep a stack of unused allocated memory chunks. Each memory chunk is required to be large enough to hold a
gpointer. This allows the stack to be maintained without any space overhead, since the stack pointers can be stored inside the memory chunks.There is no function to create a GLib.TrashStack. A
NULLGTrashStack*is a perfectly valid empty stack.Each piece of memory that is pushed onto the stack is cast to a
GTrashStack*.There is no longer any good reason to use GLib.TrashStack. If you have extra pieces of memory,
free()them and allocate them again later.Deprecated
since 2.48: GLib.TrashStack is deprecated without replacement