summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2018-09-22 15:19:10 -0700
committerOri Bernstein <ori@eigenstate.org>2018-09-22 15:19:10 -0700
commitba9519781df047104b22bd2285e2d608253812f1 (patch)
tree9caefe083dcadc887e9a94d7f612eda650cc3ff2 /util
parent63dc379b326e11226c34c807f210bb92af6fe602 (diff)
downloadmc-ba9519781df047104b22bd2285e2d608253812f1.tar.gz
Compile on 32 bits.
Diffstat (limited to 'util')
-rw-r--r--util/bitset.c4
-rw-r--r--util/htab.c6
2 files changed, 4 insertions, 6 deletions
diff --git a/util/bitset.c b/util/bitset.c
index 6109f9e..9d0d717 100644
--- a/util/bitset.c
+++ b/util/bitset.c
@@ -112,8 +112,8 @@ bscount(Bitset *bs)
return n;
}
-inline
-static int firstbit(size_t b)
+static inline int
+firstbit(uint64_t b)
{
int n;
static const char bits[] = {
diff --git a/util/htab.c b/util/htab.c
index eafb663..500b754 100644
--- a/util/htab.c
+++ b/util/htab.c
@@ -123,8 +123,7 @@ htput(Htab *ht, void *k, void *v)
i = (h + di) & (ht->sz - 1);
}
ht->nelt++;
-conflicted
-:
+conflicted:
if (ht->dead[i])
ht->ndead--;
ht->hashes[i] = h;
@@ -152,8 +151,7 @@ htidx(Htab *ht, void *k)
h = hash(ht, k);
i = h & (ht->sz - 1);
while (ht->hashes[i] && !ht->dead[i] && ht->hashes[i] != h) {
-searchmore
-:
+searchmore:
di++;
i = (h + di) & (ht->sz - 1);
}