* cord/cordbscs.c (CORD_substr): Remove code for non-STDC compilers.
* include/private/gc_priv.h (clock): Likewise.
* cord/de.c (beep): Replace the K&R-style function definition with
the ANSI C one.
* include/new_gc_alloc.h: Remove comment about expecting STDC
compiler.
/* n < 0 is impossible in a correct C implementation, but */
/* quite possible under SunOS 4.X. */
if (i + n > len) n = len - i;
-# ifndef __STDC__
- if (i < 0) ABORT("CORD_substr: second arg. negative");
- /* Possible only if both client and C implementation are buggy. */
- /* But empirically this happens frequently. */
-# endif
return(CORD_substr_checked(x, i, n));
}
#if defined(WIN32)
# define beep() Beep(1000 /* Hz */, 300 /* msecs */)
#elif defined(MACINTOSH)
-# define beep() SysBeep(1)
+# define beep() SysBeep(1)
#else
/*
* beep() is part of some curses packages and not others.
* We try to match the type of the builtin one, if any.
*/
-#ifdef __STDC__
- int beep(void)
-#else
- int beep()
-#endif
-{
+ int beep(void)
+ {
putc('\007', stderr);
return(0);
-}
-#endif
+ }
+#endif /* !WIN32 && !MACINTOSH */
# define NO_PREFIX -1
# define BARE_PREFIX -2
// problems. The argument for changing it is that the usual default
// allocator is usually a very bad choice for a garbage collected environment.)
//
-// This code assumes that the collector itself has been compiled with a
-// compiler that defines __STDC__ .
-//
#ifndef GC_ALLOC_H
# define MS_TIME_DIFF(a,b) ((long)((a)-(b)))
#else /* !MSWIN32, !MSWINCE, !BSD_TIME */
# include <time.h>
-# if !defined(__STDC__) && defined(SPARC) && defined(SUNOS4)
- clock_t clock(void); /* Not in time.h, where it belongs */
-# endif
# if defined(FREEBSD) && !defined(CLOCKS_PER_SEC)
# include <machine/limits.h>
# define CLOCKS_PER_SEC CLK_TCK