summaryrefslogtreecommitdiff
path: root/src/stdafx.h
diff options
context:
space:
mode:
authortruebrain <truebrain@openttd.org>2011-12-20 17:57:56 +0000
committertruebrain <truebrain@openttd.org>2011-12-20 17:57:56 +0000
commit1c9bec19993417b1f3b240f2bdb0745aa26c0cb3 (patch)
treed09407cc962ee87ac1bbbbc60951cad74c6b1db7 /src/stdafx.h
parent7a38642a1c83531a65907ae784bc03a82d35132a (diff)
downloadopenttd-1c9bec19993417b1f3b240f2bdb0745aa26c0cb3.tar.xz
(svn r23640) -Fix: stop using FORCEINLINE (1/3rd of the instances were, the others were still regular inline), but make sure inline is always a 'forced' inline (I am looking at you MSVC)
Diffstat (limited to 'src/stdafx.h')
-rw-r--r--src/stdafx.h7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/stdafx.h b/src/stdafx.h
index c75e4ca48..68f7b5d88 100644
--- a/src/stdafx.h
+++ b/src/stdafx.h
@@ -121,7 +121,6 @@
/* Stuff for GCC */
#if defined(__GNUC__)
#define NORETURN __attribute__ ((noreturn))
- #define FORCEINLINE inline
#define CDECL
#define __int64 long long
#define GCC_PACK __attribute__((packed))
@@ -137,7 +136,6 @@
#if defined(__WATCOMC__)
#define NORETURN
- #define FORCEINLINE inline
#define CDECL
#define GCC_PACK
#define WARN_FORMAT(string, args)
@@ -185,8 +183,7 @@
#include <malloc.h> // alloca()
#define NORETURN __declspec(noreturn)
- #define FORCEINLINE __forceinline
- #define inline _inline
+ #define inline __forceinline
#if !defined(WINCE)
#define CDECL _cdecl
@@ -448,7 +445,7 @@ void NORETURN CDECL error(const char *str, ...) WARN_FORMAT(1, 2);
* Version of the standard free that accepts const pointers.
* @param ptr The data to free.
*/
-static FORCEINLINE void free(const void *ptr)
+static inline void free(const void *ptr)
{
free(const_cast<void *>(ptr));
}