--- deliantra/server/include/util.h 2007/03/01 12:28:16 1.39 +++ deliantra/server/include/util.h 2007/04/21 22:57:16 1.41 @@ -20,7 +20,7 @@ #include // use a gcc extension for auto declarations until ISO C++ sanctifies them -#define AUTODECL(var,expr) typeof(expr) var = (expr) +#define auto(var,expr) typeof(expr) var = (expr) // very ugly macro that basicaly declares and initialises a variable // that is in scope for the next statement only @@ -267,7 +267,7 @@ uint32_t operator ()(uint32_t r_max) { return is_constant (r_max) - ? this->next () % r_max + ? (next () * (uint64_t)r_max) >> 32U : get_range (r_max); } @@ -275,7 +275,7 @@ int operator () (int r_min, int r_max) { return is_constant (r_min) && is_constant (r_max) - ? r_min + (*this) (max (r_max - r_min + 1, 1)) + ? r_min + operator ()(max (r_max - r_min + 1, 1)) : get_range (r_min, r_max); }