Print this page
remove support for non-ANSI compilation

*** 18,27 **** --- 18,29 ---- * information: Portions Copyright [yyyy] [name of copyright owner] * * CDDL HEADER END */ /* + * Copyright 2014 Garrett D'Amore <garrett@damore.org> + * * Copyright 2005 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ /* Copyright (c) 1988 AT&T */
*** 155,175 **** #define SEEK_END 2 #define TMP_MAX 17576 /* 26 * 26 * 26 */ #define L_tmpnam 25 /* (sizeof(P_tmpdir) + 15) */ - #if defined(__STDC__) extern __FILE __iob[_NFILE]; #define stdin (&__iob[0]) #define stdout (&__iob[1]) #define stderr (&__iob[2]) - #else - extern __FILE _iob[_NFILE]; - #define stdin (&_iob[0]) - #define stdout (&_iob[1]) - #define stderr (&_iob[2]) - #endif /* __STDC__ */ #if __cplusplus >= 199711L namespace std { #endif --- 157,170 ----
*** 197,208 **** #define sscanf _sscanf_c89 #endif #endif /* !defined(_LP64) && !defined(_LONGLONG_TYPE) */ - #if defined(__STDC__) - extern int remove(const char *); extern int rename(const char *, const char *); extern FILE *tmpfile(void); extern char *tmpnam(char *); extern int fclose(FILE *); --- 192,201 ----
*** 270,339 **** #ifndef _LP64 extern int __filbuf(FILE *); extern int __flsbuf(int, FILE *); #endif /* _LP64 */ - #else /* !defined __STDC__ */ - - extern int remove(); - extern int rename(); - extern FILE *tmpfile(); - extern char *tmpnam(); - extern int fclose(); - extern int fflush(); - extern FILE *fopen(); - extern FILE *freopen(); - extern void setbuf(); - extern int setvbuf(); - extern int fprintf(); - extern int fscanf(); - extern int printf(); - extern int scanf(); - extern int sprintf(); - extern int sscanf(); - extern int vfprintf(); - extern int vprintf(); - extern int vsprintf(); - extern int fgetc(); - extern char *fgets(); - extern int fputc(); - extern int fputs(); - extern int getc(); - extern int getchar(); - extern char *gets(); - extern int putc(); - extern int putchar(); - extern int puts(); - extern int ungetc(); - extern size_t fread(); - extern size_t fwrite(); - extern int fgetpos(); - extern int fseek(); - extern int fsetpos(); - extern long ftell(); - extern void rewind(); - extern void clearerr(); - extern int feof(); - extern int ferror(); - extern void perror(); - - #ifndef _LP64 - extern int _filbuf(); - extern int _flsbuf(); - #endif /* _LP64 */ - - #endif /* __STDC__ */ - #if __cplusplus >= 199711L } #endif /* end of namespace std */ #if !defined(__lint) #if !defined(_REENTRANT) && !defined(_LP64) - #ifdef __STDC__ #if __cplusplus >= 199711L namespace std { inline int getc(FILE *_p) { return (--_p->_cnt < 0 ? __filbuf(_p) : (int)*_p->_ptr++); } inline int putc(int _x, FILE *_p) { --- 263,280 ----
*** 343,357 **** #else /* __cplusplus >= 199711L */ #define getc(p) (--(p)->_cnt < 0 ? __filbuf(p) : (int)*(p)->_ptr++) #define putc(x, p) (--(p)->_cnt < 0 ? __flsbuf((x), (p)) \ : (int)(*(p)->_ptr++ = (unsigned char) (x))) #endif /* __cplusplus >= 199711L */ - #else /* __STDC__ */ - #define getc(p) (--(p)->_cnt < 0 ? _filbuf(p) : (int)*(p)->_ptr++) - #define putc(x, p) (--(p)->_cnt < 0 ? _flsbuf((x), (p)) : \ - (int)(*(p)->_ptr++ = (unsigned char) (x))) - #endif /* __STDC__ */ #endif /* !defined(_REENTRANT) && !defined(_LP64) */ #ifndef _REENTRANT --- 284,293 ----