Menu

#30 fix gcc-3.4 compile error

open
nobody
None
5
2006-04-26
2006-04-26
Anonymous
No

This patch fixes cube build error with gcc3.4.

--- cube_source/src/tools.h- 2005-08-14 19:09:22 +0400
+++ cube_source/src/tools.h 2006-04-26 13:09:57 +0400
@@ -147,6 +147,7 @@ struct pool
void allocnext(size_t allocsize);
};

+pool *gp();
template <class T> struct vector
{
T *buf;
@@ -270,7 +271,6 @@ template <class T> struct hashtable

#define enumerate(ht,t,e,b) loopi(ht->size) for(ht->enumc = ht->table[i]; ht->enumc; ht->enumc = ht->enumc->next) { t e = &ht->enumc->data; b; }

-pool *gp();
inline char *newstring(char *s) { return gp()->string(s); };
inline char *newstring(char *s, size_t l) { return gp()->string(s, l); };
inline char *newstringbuf(char *s) { return gp()->stringbuf(s); };

Discussion


Log in to post a comment.

MongoDB Logo MongoDB