summaryrefslogtreecommitdiff
path: root/src/stdafx.h
diff options
context:
space:
mode:
authorKUDr <KUDr@openttd.org>2007-01-26 08:37:48 +0000
committerKUDr <KUDr@openttd.org>2007-01-26 08:37:48 +0000
commit1943e8cb8caf49f398fc61420bb7d905bd870c73 (patch)
tree716a1e142a886956378b37122f0af47b8ee93366 /src/stdafx.h
parent561daaba2c78ad9ffdd124318a704d6a63a45854 (diff)
downloadopenttd-1943e8cb8caf49f398fc61420bb7d905bd870c73.tar.xz
(svn r8413) -Fix [MORPHOS]: disable #define offsetof conflict on Morphos (seems that g++ 2.95 defines it anyway)
Diffstat (limited to 'src/stdafx.h')
-rw-r--r--src/stdafx.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/stdafx.h b/src/stdafx.h
index 3de865245..fb00c11fa 100644
--- a/src/stdafx.h
+++ b/src/stdafx.h
@@ -310,7 +310,9 @@ assert_compile(sizeof(uint8) == 1);
# define offsetof(s,m) (size_t)&(((s *)0)->m)
#else /* __cplusplus */
# define cpp_offsetof(s,m) (((size_t)&reinterpret_cast<const volatile char&>((((s*)(char*)8)->m))) - 8)
-# define offsetof(s,m) cpp_offsetof(s, m)
+# ifndef __MORPHOS__
+# define offsetof(s,m) cpp_offsetof(s, m)
+# endif /* !__MORPHOS__ */
#endif /* __cplusplus */