Minor edits, mostly tweaks of the API documentation

darcs-hash:20060123233347-ac50b-44ebb96ba202c062739ba3d183519e28a95511b2.gz
This commit is contained in:
axel 2006-01-24 09:33:47 +10:00
parent ba177b48d5
commit 8df21a1cb1
3 changed files with 52 additions and 36 deletions

View File

@ -823,8 +823,6 @@ static int builtin_functions( wchar_t **argv )
} }
/* /*
Erase, desc and list are mutually exclusive Erase, desc and list are mutually exclusive
*/ */
@ -840,7 +838,6 @@ static int builtin_functions( wchar_t **argv )
return 1; return 1;
} }
if( erase ) if( erase )
{ {
int i; int i;

View File

@ -1234,7 +1234,7 @@ static const wchar_t *complete_function_desc( const wchar_t *fn )
\param cmd the command string to find completions for \param cmd the command string to find completions for
B\param comp the list to add all completions to \param comp the list to add all completions to
*/ */
static void complete_cmd( const wchar_t *cmd, static void complete_cmd( const wchar_t *cmd,
array_list_t *comp ) array_list_t *comp )

45
util.h
View File

@ -165,19 +165,29 @@ float minf( float a, float b );
*/ */
void q_init( dyn_queue_t *q ); void q_init( dyn_queue_t *q );
/** Destroy the queue */ /**
Destroy the queue
*/
void q_destroy( dyn_queue_t *q ); void q_destroy( dyn_queue_t *q );
/** Insert element into queue */ /**
Insert element into queue
*/
int q_put( dyn_queue_t *q, void *e ); int q_put( dyn_queue_t *q, void *e );
/** Remove and return next element from queue */ /**
Remove and return next element from queue
*/
void *q_get( dyn_queue_t *q); void *q_get( dyn_queue_t *q);
/** Return next element from queue without removing it */ /**
Return next element from queue without removing it
*/
void *q_peek( dyn_queue_t *q); void *q_peek( dyn_queue_t *q);
/** Returns 1 if the queue is empty, 0 otherwise */ /**
Returns 1 if the queue is empty, 0 otherwise
*/
int q_empty( dyn_queue_t *q ); int q_empty( dyn_queue_t *q );
/** /**
@ -252,14 +262,14 @@ void hash_get_data( hash_table_t *h,
array_list_t *arr ); array_list_t *arr );
/** /**
Call the function func for each key/data pair in the table Call the function func for each key/data pair in the table
*/ */
void hash_foreach( hash_table_t *h, void hash_foreach( hash_table_t *h,
void (*func)( const void *, const void * ) ); void (*func)( const void *, const void * ) );
/** /**
Same as hash_foreach, but the function func takes an additional Same as hash_foreach, but the function func takes an additional
argument, which is provided by the caller in the variable aux argument, which is provided by the caller in the variable aux
*/ */
void hash_foreach2( hash_table_t *h, void (*func)( const void *, void hash_foreach2( hash_table_t *h, void (*func)( const void *,
const void *, const void *,
@ -273,7 +283,8 @@ int hash_str_func( const void *data );
/** /**
Hash comparison function suitable for character strings Hash comparison function suitable for character strings
*/ */
int hash_str_cmp( const void *a, const void *b ); int hash_str_cmp( const void *a,
const void *b );
/** /**
Hash function suitable for wide character strings. Hash function suitable for wide character strings.
@ -283,7 +294,8 @@ int hash_wcs_func( const void *data );
/** /**
Hash comparison function suitable for wide character strings Hash comparison function suitable for wide character strings
*/ */
int hash_wcs_cmp( const void *a, const void *b ); int hash_wcs_cmp( const void *a,
const void *b );
/** /**
Initialize the priority queue Initialize the priority queue
@ -296,12 +308,12 @@ void pq_init( priority_queue_t *q,
/** /**
Add element to the queue Add element to the queue
\param q the queue \param q the queue
\param e the new element \param e the new element
*/ */
int pq_put( priority_queue_t *q, int pq_put( priority_queue_t *q,
void *e ); void *e );
/** /**
Removes and returns the last entry in the priority queue Removes and returns the last entry in the priority queue
*/ */
@ -445,6 +457,10 @@ void al_foreach2( array_list_t *l, void (*func)(const void *, void *), void *aux
int wcsfilecmp( const wchar_t *a, const wchar_t *b ); int wcsfilecmp( const wchar_t *a, const wchar_t *b );
/*
String buffer functions
*/
/** /**
Initialize the specified string_buffer Initialize the specified string_buffer
*/ */
@ -503,6 +519,9 @@ void sb_destroy( string_buffer_t * );
*/ */
void sb_clear( string_buffer_t * ); void sb_clear( string_buffer_t * );
/*
Buffer functions
*/
/** /**
Initialize the specified buffer_t Initialize the specified buffer_t