summaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorTyge Løvset <[email protected]>2021-09-11 22:15:43 +0200
committerTyge Løvset <[email protected]>2021-09-11 22:15:43 +0200
commit658019e1e53ad1ccbca5c623b7199c445eab8b86 (patch)
tree609f3f69e0058984f7b30b06ad2e6cfb9736fb27 /include
parentaba4aad980ff7f171f53c34915da0755f0ed079c (diff)
downloadSTC-modified-658019e1e53ad1ccbca5c623b7199c445eab8b86.tar.gz
STC-modified-658019e1e53ad1ccbca5c623b7199c445eab8b86.zip
Updated benchmarks to newstyle.
Diffstat (limited to 'include')
-rw-r--r--include/stc/cdeq.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/stc/cdeq.h b/include/stc/cdeq.h
index 7658b7a6..c6993427 100644
--- a/include/stc/cdeq.h
+++ b/include/stc/cdeq.h
@@ -234,7 +234,7 @@ cx_memb(_realloc_)(Self* self, size_t n) {
size_t sz = rep->size, cap = (size_t) (sz*1.7) + n + 7;
size_t nfront = _cdeq_nfront(self);
rep = (struct cdeq_rep*) c_realloc(rep->cap ? rep : NULL,
- offsetof(struct cdeq_rep, base) + cap*sizeof(i_val));
+ offsetof(struct cdeq_rep, base) + cap*sizeof(i_val));
rep->size = sz, rep->cap = cap;
self->_base = (cx_value_t *) rep->base;
self->data = self->_base + nfront;
@@ -257,7 +257,7 @@ cx_memb(_expand_right_half_)(Self* self, size_t idx, size_t n) {
#endif
memmove(self->_base + pos, self->data, idx*sizeof(i_val));
memmove(self->data + pos + idx + n, self->data + idx, (sz - idx)*sizeof(i_val));
- self->data = ((cx_value_t *) self->_base) + pos;
+ self->data = self->_base + pos;
}
}