From a07ae8bd0769097e10fa627c1f0a5da9db1995de Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Thu, 19 Nov 1992 20:51:13 +0000 Subject: [PATCH] GNU text utilities --- lib/regex.c | 4 ++++ lib/regex.h | 5 +++++ lib/strtol.c | 2 +- 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/lib/regex.c b/lib/regex.c index 3129ed499..71aa4cc87 100644 --- a/lib/regex.c +++ b/lib/regex.c @@ -135,7 +135,11 @@ init_syntax_once () (Per Bothner suggested the basic approach.) */ #undef SIGN_EXTEND_CHAR #if __STDC__ +#ifndef VMS #define SIGN_EXTEND_CHAR(c) ((signed char) (c)) +#else /* On VMS, VAXC doesn't recognize `signed' before `char' */ +#define SIGN_EXTEND_CHAR(c) ((char) (c)) +#endif /* VMS */ #else /* As in Harbison and Steele. */ #define SIGN_EXTEND_CHAR(c) ((((unsigned char) (c)) ^ 128) - 128) diff --git a/lib/regex.h b/lib/regex.h index 87824ef47..ef8e9a366 100644 --- a/lib/regex.h +++ b/lib/regex.h @@ -20,6 +20,11 @@ #ifndef __REGEXP_LIBRARY_H__ #define __REGEXP_LIBRARY_H__ +#ifdef VMS +/* POSIX says that size_t should be in stddef.h. */ +#include +#endif + /* POSIX says that must be included before . */ /* The following bits are used to determine the regexp syntax we diff --git a/lib/strtol.c b/lib/strtol.c index 09d8f86e9..d91db4bfe 100644 --- a/lib/strtol.c +++ b/lib/strtol.c @@ -36,7 +36,7 @@ Cambridge, MA 02139, USA. */ extern int errno; #endif -#if !__STDC__ +#if !__STDC__ && !defined(const) #define const #endif -- 2.11.0