X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=include%2FHsBase.h;h=3c6b051cbf510f05c58d90c668846e7b0e5d2fb9;hb=4ac794bfda775a2c0b03ad95506f6a415193610d;hp=a917b96727c0eec4385fc58e7eea702576849de1;hpb=7cd377be38cf40c6fc95d8d7a9774d94a3260808;p=ghc-base.git diff --git a/include/HsBase.h b/include/HsBase.h index a917b96..3c6b051 100644 --- a/include/HsBase.h +++ b/include/HsBase.h @@ -1,14 +1,14 @@ /* ----------------------------------------------------------------------------- - * $Id: HsBase.h,v 1.15 2002/10/03 12:43:50 panne Exp $ + * $Id: HsBase.h,v 1.21 2003/05/08 16:06:41 ross Exp $ * * (c) The University of Glasgow 2001-2002 * - * Definitions for package `core' which are visible in Haskell land. + * Definitions for package `base' which are visible in Haskell land. * * ---------------------------------------------------------------------------*/ -#ifndef HSCORE_H -#define HSCORE_H +#ifndef __HSBASE_H__ +#define __HSBASE_H__ #include "config.h" #include "HsFFI.h" @@ -119,6 +119,9 @@ HsInt rawSystemCmd(HsAddr cmd); /* in inputReady.c */ int inputReady(int fd, int msecs, int isSock); +/* in writeError.c */ +void writeErrString__(HsAddr msg_hdr, HsAddr msg, HsInt len); + /* ----------------------------------------------------------------------------- 64-bit operations, defined in longlong.c -------------------------------------------------------------------------- */ @@ -374,10 +377,10 @@ __hscore_PrelHandle_write( HsInt fd, HsBool isSock, HsAddr ptr, { #if defined(__MINGW32__) if (isSock) { - return send(fd,ptr + off, sz, 0); + return send(fd,(char *)ptr + off, sz, 0); } #endif - return write(fd,ptr + off, sz); + return write(fd,(char *)ptr + off, sz); } INLINE HsInt @@ -386,10 +389,10 @@ __hscore_PrelHandle_read( HsInt fd, HsBool isSock, HsAddr ptr, { #if defined(__MINGW32__) if (isSock) { - return recv(fd,ptr + off, sz, 0); + return recv(fd,(char *)ptr + off, sz, 0); } #endif - return read(fd,ptr + off, sz); + return read(fd,(char *)ptr + off, sz); } @@ -620,7 +623,9 @@ INLINE int __hsposix_SIGTTIN() { return SIGTTIN; } INLINE int __hsposix_SIGTTOU() { return SIGTTOU; } INLINE int __hsposix_SIGUSR1() { return SIGUSR1; } INLINE int __hsposix_SIGUSR2() { return SIGUSR2; } +#if HAVE_SIGPOLL INLINE int __hsposix_SIGPOLL() { return SIGPOLL; } +#endif INLINE int __hsposix_SIGPROF() { return SIGPROF; } INLINE int __hsposix_SIGSYS() { return SIGSYS; } INLINE int __hsposix_SIGTRAP() { return SIGTRAP; } @@ -632,7 +637,7 @@ INLINE int __hsposix_SIGXFSZ() { return SIGXFSZ; } INLINE int __hsposix_SIG_BLOCK() { return SIG_BLOCK; } INLINE int __hsposix_SIG_UNBLOCK() { return SIG_SETMASK; } INLINE int __hsposix_SIG_SETMASK() { return SIG_UNBLOCK; } -#endif // mingw32_TARGET_OS +#endif /* mingw32_TARGET_OS */ -#endif +#endif /* __HSBASE_H__ */