The GSequence data structure has the API of a list, but is implemented internally with a balanced binary tree. This means that it is possible to maintain a sorted list of n elements in time O(n log n). The data contained in each element can be either integer values, by using of the Type Conversion Macros, or simply pointers to any type of data.