From: TimePath Date: Sun, 19 Apr 2015 10:52:47 +0000 (+1000) Subject: Declare `stoi` and `itos` when QCC_SUPPORT_INT X-Git-Tag: xonotic-v0.8.1~69^2~1 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=5e71f197737816c83f7cb97a7473a1eed43895a7;p=xonotic%2Fxonotic-data.pk3dir.git Declare `stoi` and `itos` when QCC_SUPPORT_INT --- diff --git a/qcsrc/common/util-pre.qh b/qcsrc/common/util-pre.qh index 022f68721..f24620037 100644 --- a/qcsrc/common/util-pre.qh +++ b/qcsrc/common/util-pre.qh @@ -22,7 +22,11 @@ #define stoi(s) stof(s) #define stob(s) stof(s) - #define itos(s) ftos(s) + #define itos(i) ftos(i) +#else + #define stoi(s) ((int) stof(s)) + #define stob(s) ((bool) stof(s)) + #define itos(i) ftos(i) #endif #ifndef QCC_SUPPORT_BOOL