summaryrefslogtreecommitdiffhomepage
path: root/include/stc/forward.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/stc/forward.h')
-rw-r--r--include/stc/forward.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/include/stc/forward.h b/include/stc/forward.h
index 04566b98..1a85f1ed 100644
--- a/include/stc/forward.h
+++ b/include/stc/forward.h
@@ -57,7 +57,7 @@ typedef struct { const char* str; size_t size; } csview;
typedef char csview_value;
typedef union {
const char *ref;
- csview chr;
+ struct { csview chr; const char *_end; } u8;
} csview_iter, cstr_iter;
#define c_true(...) __VA_ARGS__
@@ -73,12 +73,12 @@ typedef union {
#define _c_carr2_types(SELF, VAL) \
typedef VAL SELF##_value; \
- typedef struct { SELF##_value *ref; } SELF##_iter; \
+ typedef struct { SELF##_value *ref, *_end; } SELF##_iter; \
typedef struct { SELF##_value **data; size_t xdim, ydim; } SELF
#define _c_carr3_types(SELF, VAL) \
typedef VAL SELF##_value; \
- typedef struct { SELF##_value *ref; } SELF##_iter; \
+ typedef struct { SELF##_value *ref, *_end; } SELF##_iter; \
typedef struct { SELF##_value ***data; size_t xdim, ydim, zdim; } SELF
#define _c_cbox_types(SELF, VAL) \
@@ -89,7 +89,7 @@ typedef union {
#define _c_cdeq_types(SELF, VAL) \
typedef VAL SELF##_value; \
- typedef struct {SELF##_value *ref; } SELF##_iter; \
+ typedef struct {SELF##_value *ref, *_end; } SELF##_iter; \
typedef struct {SELF##_value *_base, *data;} SELF
#define _c_clist_types(SELF, VAL) \
@@ -120,7 +120,7 @@ typedef union {
} SELF##_result; \
\
typedef struct { \
- SELF##_value *ref; \
+ SELF##_value *ref, *_end; \
uint8_t* _hx; \
} SELF##_iter; \
\
@@ -186,7 +186,7 @@ typedef union {
#endif
#define _c_cstack_types(SELF, VAL) \
typedef VAL SELF##_value; \
- typedef struct { SELF##_value *ref; } SELF##_iter; \
+ typedef struct { SELF##_value *ref, *_end; } SELF##_iter; \
typedef struct SELF { \
SELF##_value* data; \
size_t size, capacity; \
@@ -209,7 +209,7 @@ typedef union {
#define _c_cvec_types(SELF, VAL) \
typedef VAL SELF##_value; \
- typedef struct { SELF##_value *ref; } SELF##_iter; \
+ typedef struct { SELF##_value *ref, *_end; } SELF##_iter; \
typedef struct { SELF##_value *data; } SELF
#endif // STC_FORWARD_H_INCLUDED