Added cor/bitset.h
This commit is contained in:
1 parent
160c6d4d1c
commit
7c82fff41d
3 files changed
+34
-8
No files matched your search
+5
-8
@@ -36,17 +36,14 @@
|
||||
* ------------------------------------------------------------------------- */
|
||||
#include "../cor/core.h"
|
||||
|
||||
/* -------------------------------------------------------------------------
|
||||
* BitSet Implementation
|
||||
* ------------------------------------------------------------------------- */
|
||||
#include "../cor/bitset.h"
|
||||
|
||||
/* -------------------------------------------------------------------------
|
||||
* BitSet specific
|
||||
* ------------------------------------------------------------------------- */
|
||||
/* Defines the underlaying data type for the bitset array */
|
||||
/* Possible values: uint64_t, uint32_t, uint16_t, uint8_t, size_t */
|
||||
#ifndef CMC_BITSET_WORD_TYPE
|
||||
#define CMC_BITSET_WORD_TYPE uint32_t
|
||||
#endif /* CMC_BITSET_WORD_TYPE */
|
||||
|
||||
typedef CMC_BITSET_WORD_TYPE cmc_bitset_word;
|
||||
|
||||
/* to_string format */
|
||||
static const char *cmc_string_fmt_bitset = "struct %s "
|
||||
"at %p { "
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
/**
|
||||
* bitset.h
|
||||
*
|
||||
* Creation Date: 20/05/2020
|
||||
*
|
||||
* Authors:
|
||||
* Leonardo Vencovsky (https://github.com/LeoVen)
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
* Things commonly used by bitset collections.
|
||||
*/
|
||||
|
||||
#ifndef CMC_COR_BITSET_H
|
||||
#define CMC_COR_BITSET_H
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
/* Defines the underlaying data type for the bitset array */
|
||||
/* Possible values: uint64_t, uint32_t, uint16_t, uint8_t, size_t */
|
||||
#ifndef CMC_BITSET_WORD_TYPE
|
||||
#define CMC_BITSET_WORD_TYPE uint32_t
|
||||
#endif /* CMC_BITSET_WORD_TYPE */
|
||||
|
||||
typedef CMC_BITSET_WORD_TYPE cmc_bitset_word;
|
||||
|
||||
#endif /* CMC_COR_BITSET_H */
|
||||
@@ -25,6 +25,7 @@
|
||||
#define CMC_COLLECTION_GENERATE_SOURCE(C, PFX, SNAME, K, V) \
|
||||
CMC_CONCAT(C, SOURCE)(PFX, SNAME, K, V)
|
||||
|
||||
#include "cor/bitset.h" /* Added in 20/05/2020 */
|
||||
#include "cor/core.h" /* Added in 17/03/2020 */
|
||||
#include "cor/flags.h" /* Added in 14/05/2020 */
|
||||
#include "cor/hashtable.h" /* Added in 17/03/2020 */
|
||||
|
||||
Reference in new issue
Block a user