Skip to content

Commit a4976c1

Browse files
committed
Doxygen fixes. Use DISTRIBUTE_GROUP_DOC.
- DISTRIBUTE_GROUP_DOC makes doxygen give several fields the same doc: mn_hi + mn_lo in MDB_node. - With mdb_mutex_t + mdb_mutexref_t, instead split them up.
1 parent 7895f46 commit a4976c1

File tree

2 files changed

+17
-15
lines changed

2 files changed

+17
-15
lines changed

libraries/liblmdb/Doxyfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ IDL_PROPERTY_SUPPORT = YES
253253
# member in the group (if any) for the other members of the group. By default
254254
# all members of a group must be documented explicitly.
255255

256-
DISTRIBUTE_GROUP_DOC = NO
256+
DISTRIBUTE_GROUP_DOC = YES
257257

258258
# Set the SUBGROUPING tag to YES (the default) to allow class member groups of
259259
# the same type (for instance a group of public functions) to be put as a

libraries/liblmdb/mdb.c

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -341,15 +341,15 @@ mdb_sem_wait(sem_t *sem)
341341
}
342342

343343
#else /* MDB_USE_POSIX_MUTEX: */
344-
/** Shared mutex/semaphore as it is stored (mdb_mutex_t), and as
345-
* local variables keep it (mdb_mutexref_t).
344+
/** Shared mutex/semaphore as the original is stored.
346345
*
347-
* When #mdb_mutexref_t is a pointer declaration and #mdb_mutex_t is
348-
* not, then it is array[size 1] so it can be assigned to a pointer.
349-
* @{
346+
* Not for copies. Instead it can be assigned to an #mdb_mutexref_t.
347+
* When mdb_mutexref_t is a pointer and mdb_mutex_t is not, then it
348+
* is array[size 1] so it can be assigned to the pointer.
350349
*/
351-
typedef pthread_mutex_t mdb_mutex_t[1], *mdb_mutexref_t;
352-
/* @} */
350+
typedef pthread_mutex_t mdb_mutex_t[1];
351+
/** Reference to an #mdb_mutex_t */
352+
typedef pthread_mutex_t *mdb_mutexref_t;
353353
/** Lock the reader or writer mutex.
354354
* Returns 0 or a code to give #mdb_mutex_failed(), as in #LOCK_MUTEX().
355355
*/
@@ -874,19 +874,21 @@ typedef struct MDB_page {
874874
/** Header for a single key/data pair within a page.
875875
* Used in pages of type #P_BRANCH and #P_LEAF without #P_LEAF2.
876876
* We guarantee 2-byte alignment for 'MDB_node's.
877+
*
878+
* #mn_lo and #mn_hi are used for data size on leaf nodes, and for child
879+
* pgno on branch nodes. On 64 bit platforms, #mn_flags is also used
880+
* for pgno. (Branch nodes have no flags). Lo and hi are in host byte
881+
* order in case some accesses can be optimized to 32-bit word access.
877882
*/
878883
typedef struct MDB_node {
879-
/** lo and hi are used for data size on leaf nodes and for
880-
* child pgno on branch nodes. On 64 bit platforms, flags
881-
* is also used for pgno. (Branch nodes have no flags).
882-
* They are in host byte order in case that lets some
883-
* accesses be optimized into a 32-bit word access.
884-
*/
884+
/** part of data size or pgno
885+
* @{ */
885886
#if BYTE_ORDER == LITTLE_ENDIAN
886-
unsigned short mn_lo, mn_hi; /**< part of data size or pgno */
887+
unsigned short mn_lo, mn_hi;
887888
#else
888889
unsigned short mn_hi, mn_lo;
889890
#endif
891+
/** @} */
890892
/** @defgroup mdb_node Node Flags
891893
* @ingroup internal
892894
* Flags for node headers.

0 commit comments

Comments
 (0)