aboutsummaryrefslogtreecommitdiff
path: root/externals/grill/flext/source/flmap.h
diff options
context:
space:
mode:
authorThomas Grill <xovo@users.sourceforge.net>2006-10-27 13:34:56 +0000
committerThomas Grill <xovo@users.sourceforge.net>2006-10-27 13:34:56 +0000
commit214066a139e6c680e8517c89a07431a9649321a0 (patch)
tree7d07326c1f6e5bc446f766db0022eaa90c8ea603 /externals/grill/flext/source/flmap.h
parent021708ab4cee3245e2306cb107f67d85f00823c1 (diff)
fix for Codewarrior compilation
update docs fixed anything/symbol message mixup (thanks to Stefano Papetti) fixed typos, dates, contact info added gcc branch hinting svn path=/trunk/; revision=6170
Diffstat (limited to 'externals/grill/flext/source/flmap.h')
-rw-r--r--externals/grill/flext/source/flmap.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/externals/grill/flext/source/flmap.h b/externals/grill/flext/source/flmap.h
index 69204e2e..796e9549 100644
--- a/externals/grill/flext/source/flmap.h
+++ b/externals/grill/flext/source/flmap.h
@@ -58,7 +58,7 @@ public:
void *insert(int tsize,size_t k,void *t)
{
void *r;
- if(n)
+ if(LIKELY(n))
r = _set(tsize,k,t);
else {
data[n++](k,t);
@@ -68,11 +68,11 @@ public:
return r;
}
- void *find(int tsize,size_t k) const { return n?_find(tsize,k):0; }
+ void *find(int tsize,size_t k) const { return LIKELY(n)?_find(tsize,k):0; }
void *remove(int tsize,size_t k)
{
- void *r = n?_remove(tsize,k):0;
+ void *r = LIKELY(n)?_remove(tsize,k):0;
// check(tsize);
return r;
}
@@ -213,7 +213,7 @@ public:
inline T remove(K k)
{
void *d = TableAnyMap::remove(N,*(size_t *)&k);
- if(d) --count;
+ if(LIKELY(d)) --count;
return (T)d;
}