library is now C++ compatible :^)

This commit is contained in:
2026-01-15 10:22:01 -05:00
parent 11f1a7e7c3
commit b0db2effc7
19 changed files with 192 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
#ifndef __NICKEL_ARENA_H_
#define __NICKEL_ARENA_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_ARENA_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_ARGPARSE_H_
#define __NICKEL_ARGPARSE_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_ARGPARSE_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_BITMAN_H_
#define __NICKEL_BITMAN_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_BITMAN_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_BUF_H_
#define __NICKEL_BUF_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_BUF_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_CTASSERT_H_
#define __NICKEL_CTASSERT_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_CTASSERT_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_DEFER_H_
#define __NICKEL_DEFER_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_DEFER_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_HASHMAP_H_
#define __NICKEL_HASHMAP_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_HASHMAP_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_INI_H_
#define __NICKEL_INI_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_INI_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_IO_H_
#define __NICKEL_IO_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_IO_H_ */

View File

@@ -6,6 +6,10 @@
#include <stdint.h>
#include <stdbool.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef struct ni_list_node {
struct ni_list_node* next;
struct ni_list_node* prev;
@@ -65,4 +69,8 @@ static inline ni_list_node* ni_list__get_back(ni_list* l) {
#define NI_LIST_CONTAINER_OF(ptr, type, member) \
((type*)((uint8_t*)(ptr) - offsetof(type, member)))
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_LINKEDLIST_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_LOG_H_
#define __NICKEL_LOG_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_LOG_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_REFCNT_H_
#define __NICKEL_REFCNT_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_REFCNT_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_RESULT_H_
#define __NICKEL_RESULT_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_RESULT_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_RINGSPSC_H_
#define __NICKEL_RINGSPSC_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_RINGSPSC_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_SPAN_H_
#define __NICKEL_SPAN_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_SPAN_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_THREADPOOL_H_
#define __NICKEL_THREADPOOL_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_THREADPOOL_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_TIMEUTIL_H_
#define __NICKEL_TIMEUTIL_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_TIMEUTIL_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_VERSION_H_
#define __NICKEL_VERSION_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_VERSION_H_ */

View File

@@ -1,4 +1,14 @@
#ifndef __NICKEL_XALLOC_H_
#define __NICKEL_XALLOC_H_
#ifdef __cplusplus
extern "C" {
#endif
/* header contents */
#ifdef __cplusplus
}
#endif
#endif /* __NICKEL_XALLOC_H_ */