Example #1
0
/**
 * Tests if the two set are not equal.
 */
bool_t set_not_equal(const set_t* cpset_first, const set_t* cpset_second)
{
    assert(cpset_first != NULL);
    assert(cpset_second != NULL);

#ifdef CSTL_SET_AVL_TREE
    return _avl_tree_not_equal(&cpset_first->_t_tree, &cpset_second->_t_tree);
#else
    return _rb_tree_not_equal(&cpset_first->_t_tree, &cpset_second->_t_tree);
#endif
}
Example #2
0
/**
 * Tests if the two map are not equal.
 */
bool_t map_not_equal(const map_t* cpmap_first, const map_t* cpmap_second)
{
    assert(cpmap_first != NULL);
    assert(cpmap_second != NULL);
    assert(_pair_is_inited(&cpmap_first->_pair_temp));
    assert(_pair_is_inited(&cpmap_second->_pair_temp));

    if(cpmap_first->_bfun_keycompare != cpmap_second->_bfun_keycompare)
    {
        return true;
    }
#ifdef CSTL_MAP_AVL_TREE
    return _avl_tree_not_equal(&cpmap_first->_t_tree, &cpmap_second->_t_tree);
#else
    return _rb_tree_not_equal(&cpmap_first->_t_tree, &cpmap_second->_t_tree);
#endif
}