Bitvec now builds in C++

This commit is contained in:
2025-08-01 00:47:08 -04:00
parent 4284c308be
commit 9ddcb3c509
5 changed files with 9 additions and 5 deletions

View File

@ -66,8 +66,8 @@ flenser_SOURCES = \
list.h \
url.cc \
url.hh \
bitvec.c \
bitvec.h \
bitvec.cc \
bitvec.hh \
klist.c \
klist.h \
chain.cc \

View File

@ -14,8 +14,9 @@
*/
#include "../dlib/dlib.h"
#include "bitvec.h"
#include "bitvec.hh"
extern "C" {
/**
* Create a new bitvec with 'num_bits' size
@ -65,3 +66,4 @@ void a_Bitvec_set_bit(bitvec_t *bvec, int pos)
dReturn_if_fail (pos < bvec->len);
bvec->vec[pos/BVEC_SIZE] |= 1 << (pos % BVEC_SIZE);
}
}

View File

@ -12,6 +12,7 @@ typedef struct {
} bitvec_t;
extern "C" {
/*
* Function prototypes
*/
@ -31,5 +32,6 @@ void a_Bitvec_clear(bitvec_t *bvec);
#define a_Bitvec_clear_bit(bvec,pos) \
((bvec)->vec[(pos)/BVEC_SIZE] &= ~(1 << (pos) % BVEC_SIZE))
}
#endif /* __BITVEC_H__ */

View File

@ -6,7 +6,7 @@ extern "C" {
#endif /* __cplusplus */
#include "bitvec.h"
#include "bitvec.hh"
#include "image.hh"
#include "cache.hh"

View File

@ -24,7 +24,7 @@ extern "C" {
#endif /* __cplusplus */
#include "bitvec.h"
#include "bitvec.hh"
#include "url.hh"
/*