aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdio.in.h
diff options
context:
space:
mode:
authorPaul Eggert2019-11-26 13:14:42 -0800
committerPaul Eggert2019-11-26 13:15:41 -0800
commit1b9dbca826ad8a742ab22719279f5ce3c5888a67 (patch)
treeafd37873182a84f6708c19105fedca1b4d58ddd2 /lib/stdio.in.h
parent50b52390ee5894e91965bd37f2d0c571df1e2e89 (diff)
downloademacs-1b9dbca826ad8a742ab22719279f5ce3c5888a67.tar.gz
emacs-1b9dbca826ad8a742ab22719279f5ce3c5888a67.zip
Update from Gnulib
This incorporates: 2019-11-24 Fix errors in C++ mode on mingw 2019-11-24 time_r: Fix for mingw (regression from 2019-11-16) 2019-11-24 sys_time: Fix errors in C++ mode on mingw 2019-11-22 intprops: INT_MULTIPLY_WRAPV speedup for GCC 8.4+ 2019-11-21 Disable many _GL_CXXALIASWARN on non-glibc 2019-11-21 Fix various errors in _GL_CXXALIAS_SYS invocations 2019-11-19 intprops: INT_MULTIPLY_WRAPV speedup for GCC 9.3+ 2019-11-18 stdint: Define [u]intptr_t correctly on 64-bit native Windows 2019-11-18 stdint: Fix value of WINT_MAX when we override wint_t 2019-11-18 stdint: Avoid "conflicting types" error on mingw 5.22 2019-11-16 time_r: Fix for mingw 2019-11-06 regex: now back in sync with glibc * lib/intprops.h, lib/regexec.c, lib/signal.in.h: * lib/stdint.in.h, lib/stdio.in.h, lib/stdlib.in.h: * lib/string.in.h, lib/sys_select.in.h, lib/sys_time.in.h: * lib/time.in.h, lib/unistd.in.h, m4/time_r.m4: Copy from Gnulib.
Diffstat (limited to 'lib/stdio.in.h')
-rw-r--r--lib/stdio.in.h58
1 files changed, 58 insertions, 0 deletions
diff --git a/lib/stdio.in.h b/lib/stdio.in.h
index 4a8aa55528b..7c283ad3917 100644
--- a/lib/stdio.in.h
+++ b/lib/stdio.in.h
@@ -203,7 +203,9 @@ _GL_CXXALIAS_RPL (fclose, int, (FILE *stream));
203# else 203# else
204_GL_CXXALIAS_SYS (fclose, int, (FILE *stream)); 204_GL_CXXALIAS_SYS (fclose, int, (FILE *stream));
205# endif 205# endif
206# if __GLIBC__ >= 2
206_GL_CXXALIASWARN (fclose); 207_GL_CXXALIASWARN (fclose);
208# endif
207#elif defined GNULIB_POSIXCHECK 209#elif defined GNULIB_POSIXCHECK
208# undef fclose 210# undef fclose
209/* Assume fclose is always declared. */ 211/* Assume fclose is always declared. */
@@ -247,7 +249,9 @@ _GL_CXXALIAS_RPL (fflush, int, (FILE *gl_stream));
247# else 249# else
248_GL_CXXALIAS_SYS (fflush, int, (FILE *gl_stream)); 250_GL_CXXALIAS_SYS (fflush, int, (FILE *gl_stream));
249# endif 251# endif
252# if __GLIBC__ >= 2
250_GL_CXXALIASWARN (fflush); 253_GL_CXXALIASWARN (fflush);
254# endif
251#elif defined GNULIB_POSIXCHECK 255#elif defined GNULIB_POSIXCHECK
252# undef fflush 256# undef fflush
253/* Assume fflush is always declared. */ 257/* Assume fflush is always declared. */
@@ -266,7 +270,9 @@ _GL_CXXALIAS_RPL (fgetc, int, (FILE *stream));
266# else 270# else
267_GL_CXXALIAS_SYS (fgetc, int, (FILE *stream)); 271_GL_CXXALIAS_SYS (fgetc, int, (FILE *stream));
268# endif 272# endif
273# if __GLIBC__ >= 2
269_GL_CXXALIASWARN (fgetc); 274_GL_CXXALIASWARN (fgetc);
275# endif
270#endif 276#endif
271 277
272#if @GNULIB_FGETS@ 278#if @GNULIB_FGETS@
@@ -281,7 +287,9 @@ _GL_CXXALIAS_RPL (fgets, char *, (char *s, int n, FILE *stream));
281# else 287# else
282_GL_CXXALIAS_SYS (fgets, char *, (char *s, int n, FILE *stream)); 288_GL_CXXALIAS_SYS (fgets, char *, (char *s, int n, FILE *stream));
283# endif 289# endif
290# if __GLIBC__ >= 2
284_GL_CXXALIASWARN (fgets); 291_GL_CXXALIASWARN (fgets);
292# endif
285#endif 293#endif
286 294
287#if @GNULIB_FOPEN@ 295#if @GNULIB_FOPEN@
@@ -296,7 +304,9 @@ _GL_CXXALIAS_RPL (fopen, FILE *, (const char *filename, const char *mode));
296# else 304# else
297_GL_CXXALIAS_SYS (fopen, FILE *, (const char *filename, const char *mode)); 305_GL_CXXALIAS_SYS (fopen, FILE *, (const char *filename, const char *mode));
298# endif 306# endif
307# if __GLIBC__ >= 2
299_GL_CXXALIASWARN (fopen); 308_GL_CXXALIASWARN (fopen);
309# endif
300#elif defined GNULIB_POSIXCHECK 310#elif defined GNULIB_POSIXCHECK
301# undef fopen 311# undef fopen
302/* Assume fopen is always declared. */ 312/* Assume fopen is always declared. */
@@ -324,7 +334,9 @@ _GL_CXXALIAS_RPL (fprintf, int, (FILE *fp, const char *format, ...));
324# else 334# else
325_GL_CXXALIAS_SYS (fprintf, int, (FILE *fp, const char *format, ...)); 335_GL_CXXALIAS_SYS (fprintf, int, (FILE *fp, const char *format, ...));
326# endif 336# endif
337# if __GLIBC__ >= 2
327_GL_CXXALIASWARN (fprintf); 338_GL_CXXALIASWARN (fprintf);
339# endif
328#endif 340#endif
329#if !@GNULIB_FPRINTF_POSIX@ && defined GNULIB_POSIXCHECK 341#if !@GNULIB_FPRINTF_POSIX@ && defined GNULIB_POSIXCHECK
330# if !GNULIB_overrides_fprintf 342# if !GNULIB_overrides_fprintf
@@ -375,7 +387,9 @@ _GL_CXXALIAS_RPL (fputc, int, (int c, FILE *stream));
375# else 387# else
376_GL_CXXALIAS_SYS (fputc, int, (int c, FILE *stream)); 388_GL_CXXALIAS_SYS (fputc, int, (int c, FILE *stream));
377# endif 389# endif
390# if __GLIBC__ >= 2
378_GL_CXXALIASWARN (fputc); 391_GL_CXXALIASWARN (fputc);
392# endif
379#endif 393#endif
380 394
381#if @GNULIB_FPUTS@ 395#if @GNULIB_FPUTS@
@@ -390,7 +404,9 @@ _GL_CXXALIAS_RPL (fputs, int, (const char *string, FILE *stream));
390# else 404# else
391_GL_CXXALIAS_SYS (fputs, int, (const char *string, FILE *stream)); 405_GL_CXXALIAS_SYS (fputs, int, (const char *string, FILE *stream));
392# endif 406# endif
407# if __GLIBC__ >= 2
393_GL_CXXALIASWARN (fputs); 408_GL_CXXALIASWARN (fputs);
409# endif
394#endif 410#endif
395 411
396#if @GNULIB_FREAD@ 412#if @GNULIB_FREAD@
@@ -405,7 +421,9 @@ _GL_CXXALIAS_RPL (fread, size_t, (void *ptr, size_t s, size_t n, FILE *stream));
405# else 421# else
406_GL_CXXALIAS_SYS (fread, size_t, (void *ptr, size_t s, size_t n, FILE *stream)); 422_GL_CXXALIAS_SYS (fread, size_t, (void *ptr, size_t s, size_t n, FILE *stream));
407# endif 423# endif
424# if __GLIBC__ >= 2
408_GL_CXXALIASWARN (fread); 425_GL_CXXALIASWARN (fread);
426# endif
409#endif 427#endif
410 428
411#if @GNULIB_FREOPEN@ 429#if @GNULIB_FREOPEN@
@@ -423,7 +441,9 @@ _GL_CXXALIAS_RPL (freopen, FILE *,
423_GL_CXXALIAS_SYS (freopen, FILE *, 441_GL_CXXALIAS_SYS (freopen, FILE *,
424 (const char *filename, const char *mode, FILE *stream)); 442 (const char *filename, const char *mode, FILE *stream));
425# endif 443# endif
444# if __GLIBC__ >= 2
426_GL_CXXALIASWARN (freopen); 445_GL_CXXALIASWARN (freopen);
446# endif
427#elif defined GNULIB_POSIXCHECK 447#elif defined GNULIB_POSIXCHECK
428# undef freopen 448# undef freopen
429/* Assume freopen is always declared. */ 449/* Assume freopen is always declared. */
@@ -445,7 +465,9 @@ _GL_CXXALIAS_RPL (fscanf, int, (FILE *stream, const char *format, ...));
445# else 465# else
446_GL_CXXALIAS_SYS (fscanf, int, (FILE *stream, const char *format, ...)); 466_GL_CXXALIAS_SYS (fscanf, int, (FILE *stream, const char *format, ...));
447# endif 467# endif
468# if __GLIBC__ >= 2
448_GL_CXXALIASWARN (fscanf); 469_GL_CXXALIASWARN (fscanf);
470# endif
449#endif 471#endif
450 472
451 473
@@ -496,7 +518,9 @@ _GL_CXXALIAS_RPL (fseek, int, (FILE *fp, long offset, int whence));
496# else 518# else
497_GL_CXXALIAS_SYS (fseek, int, (FILE *fp, long offset, int whence)); 519_GL_CXXALIAS_SYS (fseek, int, (FILE *fp, long offset, int whence));
498# endif 520# endif
521# if __GLIBC__ >= 2
499_GL_CXXALIASWARN (fseek); 522_GL_CXXALIASWARN (fseek);
523# endif
500#endif 524#endif
501 525
502#if @GNULIB_FSEEKO@ 526#if @GNULIB_FSEEKO@
@@ -559,7 +583,9 @@ _GL_CXXALIAS_RPL (ftell, long, (FILE *fp));
559# else 583# else
560_GL_CXXALIAS_SYS (ftell, long, (FILE *fp)); 584_GL_CXXALIAS_SYS (ftell, long, (FILE *fp));
561# endif 585# endif
586# if __GLIBC__ >= 2
562_GL_CXXALIASWARN (ftell); 587_GL_CXXALIASWARN (ftell);
588# endif
563#endif 589#endif
564 590
565#if @GNULIB_FTELLO@ 591#if @GNULIB_FTELLO@
@@ -639,7 +665,9 @@ extern size_t __REDIRECT (rpl_fwrite_unlocked,
639# define fwrite_unlocked rpl_fwrite_unlocked 665# define fwrite_unlocked rpl_fwrite_unlocked
640# endif 666# endif
641# endif 667# endif
668# if __GLIBC__ >= 2
642_GL_CXXALIASWARN (fwrite); 669_GL_CXXALIASWARN (fwrite);
670# endif
643#endif 671#endif
644 672
645#if @GNULIB_GETC@ 673#if @GNULIB_GETC@
@@ -653,7 +681,9 @@ _GL_CXXALIAS_RPL_1 (getc, rpl_fgetc, int, (FILE *stream));
653# else 681# else
654_GL_CXXALIAS_SYS (getc, int, (FILE *stream)); 682_GL_CXXALIAS_SYS (getc, int, (FILE *stream));
655# endif 683# endif
684# if __GLIBC__ >= 2
656_GL_CXXALIASWARN (getc); 685_GL_CXXALIASWARN (getc);
686# endif
657#endif 687#endif
658 688
659#if @GNULIB_GETCHAR@ 689#if @GNULIB_GETCHAR@
@@ -667,7 +697,9 @@ _GL_CXXALIAS_RPL (getchar, int, (void));
667# else 697# else
668_GL_CXXALIAS_SYS (getchar, int, (void)); 698_GL_CXXALIAS_SYS (getchar, int, (void));
669# endif 699# endif
700# if __GLIBC__ >= 2
670_GL_CXXALIASWARN (getchar); 701_GL_CXXALIASWARN (getchar);
702# endif
671#endif 703#endif
672 704
673#if @GNULIB_GETDELIM@ 705#if @GNULIB_GETDELIM@
@@ -832,7 +864,9 @@ _GL_CXXALIAS_RPL (perror, void, (const char *string));
832# else 864# else
833_GL_CXXALIAS_SYS (perror, void, (const char *string)); 865_GL_CXXALIAS_SYS (perror, void, (const char *string));
834# endif 866# endif
867# if __GLIBC__ >= 2
835_GL_CXXALIASWARN (perror); 868_GL_CXXALIASWARN (perror);
869# endif
836#elif defined GNULIB_POSIXCHECK 870#elif defined GNULIB_POSIXCHECK
837# undef perror 871# undef perror
838/* Assume perror is always declared. */ 872/* Assume perror is always declared. */
@@ -903,7 +937,9 @@ _GL_CXXALIAS_RPL (printf, int, (const char *format, ...));
903# else 937# else
904_GL_CXXALIAS_SYS (printf, int, (const char *format, ...)); 938_GL_CXXALIAS_SYS (printf, int, (const char *format, ...));
905# endif 939# endif
940# if __GLIBC__ >= 2
906_GL_CXXALIASWARN (printf); 941_GL_CXXALIASWARN (printf);
942# endif
907#endif 943#endif
908#if !@GNULIB_PRINTF_POSIX@ && defined GNULIB_POSIXCHECK 944#if !@GNULIB_PRINTF_POSIX@ && defined GNULIB_POSIXCHECK
909# if !GNULIB_overrides_printf 945# if !GNULIB_overrides_printf
@@ -926,7 +962,9 @@ _GL_CXXALIAS_RPL_1 (putc, rpl_fputc, int, (int c, FILE *stream));
926# else 962# else
927_GL_CXXALIAS_SYS (putc, int, (int c, FILE *stream)); 963_GL_CXXALIAS_SYS (putc, int, (int c, FILE *stream));
928# endif 964# endif
965# if __GLIBC__ >= 2
929_GL_CXXALIASWARN (putc); 966_GL_CXXALIASWARN (putc);
967# endif
930#endif 968#endif
931 969
932#if @GNULIB_PUTCHAR@ 970#if @GNULIB_PUTCHAR@
@@ -940,7 +978,9 @@ _GL_CXXALIAS_RPL (putchar, int, (int c));
940# else 978# else
941_GL_CXXALIAS_SYS (putchar, int, (int c)); 979_GL_CXXALIAS_SYS (putchar, int, (int c));
942# endif 980# endif
981# if __GLIBC__ >= 2
943_GL_CXXALIASWARN (putchar); 982_GL_CXXALIASWARN (putchar);
983# endif
944#endif 984#endif
945 985
946#if @GNULIB_PUTS@ 986#if @GNULIB_PUTS@
@@ -954,7 +994,9 @@ _GL_CXXALIAS_RPL (puts, int, (const char *string));
954# else 994# else
955_GL_CXXALIAS_SYS (puts, int, (const char *string)); 995_GL_CXXALIAS_SYS (puts, int, (const char *string));
956# endif 996# endif
997# if __GLIBC__ >= 2
957_GL_CXXALIASWARN (puts); 998_GL_CXXALIASWARN (puts);
999# endif
958#endif 1000#endif
959 1001
960#if @GNULIB_REMOVE@ 1002#if @GNULIB_REMOVE@
@@ -968,7 +1010,9 @@ _GL_CXXALIAS_RPL (remove, int, (const char *name));
968# else 1010# else
969_GL_CXXALIAS_SYS (remove, int, (const char *name)); 1011_GL_CXXALIAS_SYS (remove, int, (const char *name));
970# endif 1012# endif
1013# if __GLIBC__ >= 2
971_GL_CXXALIASWARN (remove); 1014_GL_CXXALIASWARN (remove);
1015# endif
972#elif defined GNULIB_POSIXCHECK 1016#elif defined GNULIB_POSIXCHECK
973# undef remove 1017# undef remove
974/* Assume remove is always declared. */ 1018/* Assume remove is always declared. */
@@ -991,7 +1035,9 @@ _GL_CXXALIAS_RPL (rename, int,
991_GL_CXXALIAS_SYS (rename, int, 1035_GL_CXXALIAS_SYS (rename, int,
992 (const char *old_filename, const char *new_filename)); 1036 (const char *old_filename, const char *new_filename));
993# endif 1037# endif
1038# if __GLIBC__ >= 2
994_GL_CXXALIASWARN (rename); 1039_GL_CXXALIASWARN (rename);
1040# endif
995#elif defined GNULIB_POSIXCHECK 1041#elif defined GNULIB_POSIXCHECK
996# undef rename 1042# undef rename
997/* Assume rename is always declared. */ 1043/* Assume rename is always declared. */
@@ -1056,7 +1102,9 @@ _GL_CXXALIAS_RPL (scanf, int, (const char *format, ...));
1056# else 1102# else
1057_GL_CXXALIAS_SYS (scanf, int, (const char *format, ...)); 1103_GL_CXXALIAS_SYS (scanf, int, (const char *format, ...));
1058# endif 1104# endif
1105# if __GLIBC__ >= 2
1059_GL_CXXALIASWARN (scanf); 1106_GL_CXXALIASWARN (scanf);
1107# endif
1060#endif 1108#endif
1061 1109
1062#if @GNULIB_SNPRINTF@ 1110#if @GNULIB_SNPRINTF@
@@ -1110,7 +1158,9 @@ _GL_CXXALIAS_RPL (sprintf, int, (char *str, const char *format, ...));
1110# else 1158# else
1111_GL_CXXALIAS_SYS (sprintf, int, (char *str, const char *format, ...)); 1159_GL_CXXALIAS_SYS (sprintf, int, (char *str, const char *format, ...));
1112# endif 1160# endif
1161# if __GLIBC__ >= 2
1113_GL_CXXALIASWARN (sprintf); 1162_GL_CXXALIASWARN (sprintf);
1163# endif
1114#elif defined GNULIB_POSIXCHECK 1164#elif defined GNULIB_POSIXCHECK
1115# undef sprintf 1165# undef sprintf
1116/* Assume sprintf is always declared. */ 1166/* Assume sprintf is always declared. */
@@ -1129,7 +1179,9 @@ _GL_CXXALIAS_RPL (tmpfile, FILE *, (void));
1129# else 1179# else
1130_GL_CXXALIAS_SYS (tmpfile, FILE *, (void)); 1180_GL_CXXALIAS_SYS (tmpfile, FILE *, (void));
1131# endif 1181# endif
1182# if __GLIBC__ >= 2
1132_GL_CXXALIASWARN (tmpfile); 1183_GL_CXXALIASWARN (tmpfile);
1184# endif
1133#elif defined GNULIB_POSIXCHECK 1185#elif defined GNULIB_POSIXCHECK
1134# undef tmpfile 1186# undef tmpfile
1135# if HAVE_RAW_DECL_TMPFILE 1187# if HAVE_RAW_DECL_TMPFILE
@@ -1240,7 +1292,9 @@ _GL_CXXALIAS_RPL (vfprintf, int, (FILE *fp, const char *format, va_list args));
1240_GL_CXXALIAS_SYS_CAST (vfprintf, int, 1292_GL_CXXALIAS_SYS_CAST (vfprintf, int,
1241 (FILE *fp, const char *format, va_list args)); 1293 (FILE *fp, const char *format, va_list args));
1242# endif 1294# endif
1295# if __GLIBC__ >= 2
1243_GL_CXXALIASWARN (vfprintf); 1296_GL_CXXALIASWARN (vfprintf);
1297# endif
1244#endif 1298#endif
1245#if !@GNULIB_VFPRINTF_POSIX@ && defined GNULIB_POSIXCHECK 1299#if !@GNULIB_VFPRINTF_POSIX@ && defined GNULIB_POSIXCHECK
1246# if !GNULIB_overrides_vfprintf 1300# if !GNULIB_overrides_vfprintf
@@ -1294,7 +1348,9 @@ _GL_CXXALIAS_RPL (vprintf, int, (const char *format, va_list args));
1294 and GCC's fixincludes did not change this to __gnuc_va_list. */ 1348 and GCC's fixincludes did not change this to __gnuc_va_list. */
1295_GL_CXXALIAS_SYS_CAST (vprintf, int, (const char *format, va_list args)); 1349_GL_CXXALIAS_SYS_CAST (vprintf, int, (const char *format, va_list args));
1296# endif 1350# endif
1351# if __GLIBC__ >= 2
1297_GL_CXXALIASWARN (vprintf); 1352_GL_CXXALIASWARN (vprintf);
1353# endif
1298#endif 1354#endif
1299#if !@GNULIB_VPRINTF_POSIX@ && defined GNULIB_POSIXCHECK 1355#if !@GNULIB_VPRINTF_POSIX@ && defined GNULIB_POSIXCHECK
1300# if !GNULIB_overrides_vprintf 1356# if !GNULIB_overrides_vprintf
@@ -1370,7 +1426,9 @@ _GL_CXXALIAS_RPL (vsprintf, int,
1370_GL_CXXALIAS_SYS_CAST (vsprintf, int, 1426_GL_CXXALIAS_SYS_CAST (vsprintf, int,
1371 (char *str, const char *format, va_list args)); 1427 (char *str, const char *format, va_list args));
1372# endif 1428# endif
1429# if __GLIBC__ >= 2
1373_GL_CXXALIASWARN (vsprintf); 1430_GL_CXXALIASWARN (vsprintf);
1431# endif
1374#elif defined GNULIB_POSIXCHECK 1432#elif defined GNULIB_POSIXCHECK
1375# undef vsprintf 1433# undef vsprintf
1376/* Assume vsprintf is always declared. */ 1434/* Assume vsprintf is always declared. */