Get rid of __inline__, just make sure "inline" is defined sanely instead.
This commit is contained in:
parent
d797ea7cd8
commit
3dc77f8a54
|
@ -14,29 +14,21 @@
|
||||||
#define __PHYSICSFS_INTERNAL__
|
#define __PHYSICSFS_INTERNAL__
|
||||||
#include "physfs_internal.h"
|
#include "physfs_internal.h"
|
||||||
|
|
||||||
#if (defined macintosh) && !(defined __MWERKS__)
|
|
||||||
#define __inline__
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (defined _MSC_VER)
|
|
||||||
#define __inline__ __inline
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef PHYSFS_Swap16
|
#ifndef PHYSFS_Swap16
|
||||||
static __inline__ PHYSFS_uint16 PHYSFS_Swap16(PHYSFS_uint16 D)
|
static inline PHYSFS_uint16 PHYSFS_Swap16(PHYSFS_uint16 D)
|
||||||
{
|
{
|
||||||
return ((D<<8)|(D>>8));
|
return ((D<<8)|(D>>8));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#ifndef PHYSFS_Swap32
|
#ifndef PHYSFS_Swap32
|
||||||
static __inline__ PHYSFS_uint32 PHYSFS_Swap32(PHYSFS_uint32 D)
|
static inline PHYSFS_uint32 PHYSFS_Swap32(PHYSFS_uint32 D)
|
||||||
{
|
{
|
||||||
return ((D<<24)|((D<<8)&0x00FF0000)|((D>>8)&0x0000FF00)|(D>>24));
|
return ((D<<24)|((D<<8)&0x00FF0000)|((D>>8)&0x0000FF00)|(D>>24));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#ifndef PHYSFS_NO_64BIT_SUPPORT
|
#ifndef PHYSFS_NO_64BIT_SUPPORT
|
||||||
#ifndef PHYSFS_Swap64
|
#ifndef PHYSFS_Swap64
|
||||||
static __inline__ PHYSFS_uint64 PHYSFS_Swap64(PHYSFS_uint64 val) {
|
static inline PHYSFS_uint64 PHYSFS_Swap64(PHYSFS_uint64 val) {
|
||||||
PHYSFS_uint32 hi, lo;
|
PHYSFS_uint32 hi, lo;
|
||||||
|
|
||||||
/* Separate into high and low 32-bit values and swap them */
|
/* Separate into high and low 32-bit values and swap them */
|
||||||
|
|
|
@ -32,7 +32,6 @@
|
||||||
/* !!! FIXME: if HAVE_ALLOCA_H would be good, too. */
|
/* !!! FIXME: if HAVE_ALLOCA_H would be good, too. */
|
||||||
#if sun
|
#if sun
|
||||||
#include <alloca.h>
|
#include <alloca.h>
|
||||||
#define __inline__ inline
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(__sun) || defined(sun)
|
#if defined(__sun) || defined(sun)
|
||||||
|
@ -50,6 +49,14 @@ extern "C" {
|
||||||
#define PHYSFS_MINIMUM_GCC_VERSION(major, minor) (0)
|
#define PHYSFS_MINIMUM_GCC_VERSION(major, minor) (0)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
/* C++ always has a real inline keyword. */
|
||||||
|
#elif (defined macintosh) && !(defined __MWERKS__)
|
||||||
|
# define inline
|
||||||
|
#elif (defined _MSC_VER)
|
||||||
|
# define inline __inline
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Interface for small allocations. If you need a little scratch space for
|
* Interface for small allocations. If you need a little scratch space for
|
||||||
* a throwaway buffer or string, use this. It will make small allocations
|
* a throwaway buffer or string, use this. It will make small allocations
|
||||||
|
|
Loading…
Reference in New Issue