libdict
Data Structure C Library
Loading...
Searching...
No Matches
dict.c File Reference
#include "dict_private.h"
Include dependency graph for dict.c:

Go to the source code of this file.

Macros

#define XSTRINGIFY(x)
 
#define STRINGIFY(x)
 

Functions

int dict_int_cmp (const void *k1, const void *k2)
 
int dict_uint_cmp (const void *k1, const void *k2)
 
int dict_long_cmp (const void *k1, const void *k2)
 
int dict_ulong_cmp (const void *k1, const void *k2)
 
int dict_ptr_cmp (const void *k1, const void *k2)
 
int dict_str_cmp (const void *k1, const void *k2)
 
unsigned dict_str_hash (const void *k)
 
size_t dict_free (dict *dct, dict_delete_func delete_func)
 
void dict_itor_free (dict_itor *itor)
 

Variables

const char *const kDictVersionString
 
void *(* dict_malloc_func )(size_t) = malloc
 
void(* dict_free_func )(void *) = free
 

Macro Definition Documentation

◆ STRINGIFY

#define STRINGIFY ( x)
Value:
#x

Definition at line 31 of file dict.c.

◆ XSTRINGIFY

#define XSTRINGIFY ( x)
Value:
#define STRINGIFY(x)
Definition dict.c:31

Definition at line 30 of file dict.c.

Function Documentation

◆ dict_free()

size_t dict_free ( dict * dct,
dict_delete_func delete_func )

Definition at line 103 of file dict.c.

◆ dict_int_cmp()

int dict_int_cmp ( const void * k1,
const void * k2 )

Definition at line 41 of file dict.c.

◆ dict_itor_free()

void dict_itor_free ( dict_itor * itor)

Definition at line 113 of file dict.c.

◆ dict_long_cmp()

int dict_long_cmp ( const void * k1,
const void * k2 )

Definition at line 57 of file dict.c.

◆ dict_ptr_cmp()

int dict_ptr_cmp ( const void * k1,
const void * k2 )

Definition at line 73 of file dict.c.

◆ dict_str_cmp()

int dict_str_cmp ( const void * k1,
const void * k2 )

Definition at line 79 of file dict.c.

◆ dict_str_hash()

unsigned dict_str_hash ( const void * k)

Definition at line 92 of file dict.c.

◆ dict_uint_cmp()

int dict_uint_cmp ( const void * k1,
const void * k2 )

Definition at line 49 of file dict.c.

◆ dict_ulong_cmp()

int dict_ulong_cmp ( const void * k1,
const void * k2 )

Definition at line 65 of file dict.c.

Variable Documentation

◆ dict_free_func

void(* dict_free_func) (void *) ( void * ) = free

Definition at line 38 of file dict.c.

◆ dict_malloc_func

void *(* dict_malloc_func) (size_t) ( size_t ) = malloc

Definition at line 37 of file dict.c.

◆ kDictVersionString

const char* const kDictVersionString
Initial value:
= "0" "."
"3" "."
"0"

Definition at line 33 of file dict.c.