diff options
| author | Tyge Løvset <[email protected]> | 2020-09-25 21:16:22 +0200 |
|---|---|---|
| committer | Tyge Løvset <[email protected]> | 2020-09-25 21:16:22 +0200 |
| commit | d9fa3685127ee1166491458e3d7e3fe1b50bdf31 (patch) | |
| tree | b3765b7a5ba8c5ce1b9633be04867ce945a2f0e8 | |
| parent | 7d98b094c9baba498078fba81e44be3299f3cc96 (diff) | |
| download | STC-modified-d9fa3685127ee1166491458e3d7e3fe1b50bdf31.tar.gz STC-modified-d9fa3685127ee1166491458e3d7e3fe1b50bdf31.zip | |
Simplified.
| -rw-r--r-- | stc/cptr.h | 12 | ||||
| -rw-r--r-- | stc/csptr.h | 15 |
2 files changed, 0 insertions, 27 deletions
@@ -87,17 +87,5 @@ int main() { } \
typedef int cptr_##X##_dud4
-#define using_cptr_5(X, Value, valueDestroy, valueCompare, hash) \
- using_cptr_4(X, Value, valueDestroy, valueCompare); \
- STC_INLINE int \
- cptr_##X##_equals(cptr_##X* x, cptr_##X* y) { \
- return valueCompare(*x, *y) == 0; \
- } \
- STC_INLINE uint32_t \
- cptr_##X##_hash(cptr_##X* self, size_t len) { \
- return hash(*self, len); \
- } \
- typedef int cptr_##X##_dud5
-
#endif
\ No newline at end of file diff --git a/stc/csptr.h b/stc/csptr.h index 42b8535a..5089ca36 100644 --- a/stc/csptr.h +++ b/stc/csptr.h @@ -117,9 +117,6 @@ typedef long atomic_count_t; *self = csptr_##X##_make(p); \
} \
\
- STC_INLINE csptr_##X##_value_t* \
- csptr_##X##_get(csptr_##X x) {return x.get;} \
-\
typedef csptr_##X csptr_##X##_t
@@ -131,16 +128,4 @@ typedef long atomic_count_t; } \
typedef int csptr_##X##_dud4
-#define using_csptr_5(X, Value, valueDestroy, valueCompare, hash) \
- using_csptr_4(X, Value, valueDestroy, valueCompare); \
- STC_INLINE int \
- csptr_##X##_equals(csptr_##X* x, csptr_##X* y) { \
- return valueCompare(x->get, y->get) == 0; \
- } \
- STC_INLINE uint32_t \
- csptr_##X##_hash(csptr_##X* self, size_t len) { \
- return hash(&self->get, len); \
- } \
- typedef int csptr_##X##_dud5
-
#endif
|
