X-Git-Url: https://perl5.git.perl.org/perl5.git/blobdiff_plain/39f7a87036eb8d13c207511143dc7f2e620b3891..8c98129fd14ae24244bde1f7f87508f60058f99b:/perlio.h diff --git a/perlio.h b/perlio.h index f1b5ede..dd1e3d5 100644 --- a/perlio.h +++ b/perlio.h @@ -1,6 +1,7 @@ /* perlio.h * - * Copyright (c) 1997-2003, Larry Wall + * Copyright (C) 1996, 1997, 1999, 2000, 2001, 2002, 2003, + * by Larry Wall and others * * You may distribute under the terms of either the GNU General Public * License or the Artistic License, as specified in the README file. @@ -194,6 +195,13 @@ extern void PerlIO_clone(pTHX_ PerlInterpreter *proto, CLONE_PARAMS *param); /* --------------------- Now prototypes for functions --------------- */ START_EXTERN_C +#ifndef __attribute__format__ +#ifdef CHECK_FORMAT +#define __attribute__format__(x,y,z) __attribute__((__format__(x,y,z))) +#else +#define __attribute__format__(x,y,z) +#endif +#endif #ifndef NEXT30_NO_ATTRIBUTE #ifndef HASATTRIBUTE /* disable GNU-cc attribute checking? */ #ifdef __attribute__ /* Avoid possible redefinition errors */ @@ -207,10 +215,7 @@ extern void PerlIO_init(pTHX); #endif #ifndef PerlIO_stdoutf extern int PerlIO_stdoutf(const char *, ...) -#ifdef CHECK_FORMAT - __attribute__ ((__format__(__printf__, 1, 2))) -#endif -; + __attribute__format__(__printf__, 1, 2); #endif #ifndef PerlIO_puts extern int PerlIO_puts(PerlIO *, const char *); @@ -270,17 +275,11 @@ extern void PerlIO_setlinebuf(PerlIO *); #endif #ifndef PerlIO_printf extern int PerlIO_printf(PerlIO *, const char *, ...) -#ifdef CHECK_FORMAT - __attribute__ ((__format__(__printf__, 2, 3))) -#endif -; + __attribute__format__(__printf__, 2, 3); #endif #ifndef PerlIO_sprintf extern int PerlIO_sprintf(char *, int, const char *, ...) -#ifdef CHECK_FORMAT - __attribute__ ((__format__(__printf__, 3, 4))) -#endif -; + __attribute__format__(__printf__, 3, 4); #endif #ifndef PerlIO_vprintf extern int PerlIO_vprintf(PerlIO *, const char *, va_list);