This commit is contained in:
Vitor Santos Costa 2015-02-09 10:30:24 +00:00
parent 9e24724f0b
commit e2cd49f408
3 changed files with 9 additions and 1 deletions

View File

@ -114,7 +114,9 @@ Yap_PutInSlot(yhandle_t slot, Term t USES_REGS)
LOCAL_SlotBase[slot] = t; LOCAL_SlotBase[slot] = t;
} }
#ifndef max
#define max(X,Y) ( X > Y ? X : Y ) #define max(X,Y) ( X > Y ? X : Y )
#endif
static inline void static inline void
ensure_slots(int N USES_REGS) ensure_slots(int N USES_REGS)

View File

@ -54,9 +54,13 @@ typedef uintptr_t UInt;
/* typedef long int Int;*/ /* typedef long int Int;*/
/* typedef unsigned long int UInt; */ /* typedef unsigned long int UInt; */
#if _WIN32
#define Int_FORMAT "%d"
#define UInt_FORMAT "%u"
#else
#define Int_FORMAT "%ld" #define Int_FORMAT "%ld"
#define UInt_FORMAT "%lu" #define UInt_FORMAT "%lu"
#endif
#else #else
#error Yap require integer types of the same size as a pointer #error Yap require integer types of the same size as a pointer
#endif #endif

View File

@ -77,9 +77,11 @@ typedef uintptr_t term_t;
#if _WIN32 #if _WIN32
#ifndef THREADS #ifndef THREADS
#ifndef WIN_PTHREADS_H
typedef int pthread_t; typedef int pthread_t;
#endif #endif
#endif #endif
#endif
typedef uintptr_t word; /* Anonymous 4 byte object */ typedef uintptr_t word; /* Anonymous 4 byte object */