Use _X_INLINE instead of ad-hoc #defines.
This commit is contained in:
parent
6ff239cb4e
commit
8dcc37520d
25
mi/miarc.c
25
mi/miarc.c
|
@ -100,37 +100,16 @@ double cbrt(double);
|
||||||
#undef max
|
#undef max
|
||||||
#undef min
|
#undef min
|
||||||
|
|
||||||
#if defined (__GNUC__) && !defined (__STRICT_ANSI__)
|
_X_INLINE static int max (const int x, const int y)
|
||||||
#define USE_INLINE
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef USE_INLINE
|
|
||||||
inline static int max (const int x, const int y)
|
|
||||||
{
|
{
|
||||||
return x>y? x:y;
|
return x>y? x:y;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline static int min (const int x, const int y)
|
_X_INLINE static int min (const int x, const int y)
|
||||||
{
|
{
|
||||||
return x<y? x:y;
|
return x<y? x:y;
|
||||||
}
|
}
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
static int
|
|
||||||
max (int x, int y)
|
|
||||||
{
|
|
||||||
return x>y? x:y;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
min (int x, int y)
|
|
||||||
{
|
|
||||||
return x<y? x:y;
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
struct bound {
|
struct bound {
|
||||||
double min, max;
|
double min, max;
|
||||||
};
|
};
|
||||||
|
|
|
@ -81,16 +81,11 @@ Equipment Corporation.
|
||||||
|
|
||||||
#include "regionstr.h"
|
#include "regionstr.h"
|
||||||
#include <X11/Xprotostr.h>
|
#include <X11/Xprotostr.h>
|
||||||
|
#include <X11/Xfuncproto.h>
|
||||||
#include "gc.h"
|
#include "gc.h"
|
||||||
#include "mi.h"
|
#include "mi.h"
|
||||||
#include "mispans.h"
|
#include "mispans.h"
|
||||||
|
|
||||||
#if defined (__GNUC__) && !defined (NO_INLINES)
|
|
||||||
#define INLINE __inline
|
|
||||||
#else
|
|
||||||
#define INLINE
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#undef assert
|
#undef assert
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
#define assert(expr) {if (!(expr)) \
|
#define assert(expr) {if (!(expr)) \
|
||||||
|
@ -506,7 +501,7 @@ miRegionCopy(dst, src)
|
||||||
*
|
*
|
||||||
*-----------------------------------------------------------------------
|
*-----------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
INLINE static int
|
_X_INLINE static int
|
||||||
miCoalesce (
|
miCoalesce (
|
||||||
RegionPtr pReg, /* Region to coalesce */
|
RegionPtr pReg, /* Region to coalesce */
|
||||||
int prevStart, /* Index of start of previous band */
|
int prevStart, /* Index of start of previous band */
|
||||||
|
@ -590,7 +585,7 @@ miCoalesce (
|
||||||
*-----------------------------------------------------------------------
|
*-----------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
INLINE static Bool
|
_X_INLINE static Bool
|
||||||
miAppendNonO (
|
miAppendNonO (
|
||||||
RegionPtr pReg,
|
RegionPtr pReg,
|
||||||
BoxPtr r,
|
BoxPtr r,
|
||||||
|
|
Loading…
Reference in New Issue