--- clang-14.log 2022-11-02 22:36:12.093766809 +1100 +++ clang-15.log 2022-11-02 22:36:12.093766809 +1100 @@ -26,91 +26,87 @@ -./test-pledge.c:6:11: warning: call to undeclared function 'pledge'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-pledge.c:6:11: error: call to undeclared function 'pledge'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return !!pledge("stdio", NULL); ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-pledge-7cee57.o: in function `main': -test-pledge.c:(.text+0xd): undefined reference to `pledge' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) ./test-sandbox_init.c:1:10: fatal error: 'sandbox.h' file not found #include ^~~~~~~~~~~ -./test-progname.c:8:13: warning: call to undeclared function 'getprogname'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-progname.c:8:13: error: call to undeclared function 'getprogname'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] progname = getprogname(); ^ ./test-progname.c:8:11: error: incompatible integer to pointer conversion assigning to 'const char *' from 'int' [-Wint-conversion] progname = getprogname(); ^ ~~~~~~~~~~~~~ +2 errors generated. -./test-recallocarray.c:10:10: warning: call to undeclared function 'recallocarray'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-recallocarray.c:10:10: error: call to undeclared function 'recallocarray'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return !recallocarray(p, 2, 3, 2); ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-recallocarray-7b1857.o: in function `main': -test-recallocarray.c:(.text+0x2a): undefined reference to `recallocarray' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-recallocarray.c:10:10: warning: call to undeclared function 'recallocarray'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-recallocarray.c:10:10: note: did you mean 'reallocarray'? +/usr/include/stdlib.h:569:14: note: 'reallocarray' declared here +extern void *reallocarray (void *__ptr, size_t __nmemb, size_t __size) + ^ +./test-recallocarray.c:10:10: error: call to undeclared function 'recallocarray'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return !recallocarray(p, 2, 3, 2); ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-recallocarray-cdfc4a.o: in function `main': -test-recallocarray.c:(.text+0x2a): undefined reference to `recallocarray' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) +./test-recallocarray.c:10:10: note: did you mean 'reallocarray'? +/usr/include/stdlib.h:569:14: note: 'reallocarray' declared here +extern void *reallocarray (void *__ptr, size_t __nmemb, size_t __size) + ^ -./test-strcasestr.c:7:13: warning: call to undeclared function 'strcasestr'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strcasestr.c:7:13: error: call to undeclared function 'strcasestr'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] char *cp = strcasestr(big, "Gst"); ^ +./test-strcasestr.c:7:13: note: did you mean 'strcasecmp'? +/usr/include/strings.h:116:12: note: 'strcasecmp' declared here +extern int strcasecmp (const char *__s1, const char *__s2) + ^ ./test-strcasestr.c:7:8: error: incompatible integer to pointer conversion initializing 'char *' with an expression of type 'int' [-Wint-conversion] char *cp = strcasestr(big, "Gst"); ^ ~~~~~~~~~~~~~~~~~~~~~~ +2 errors generated. ./test-stringlist.c:19:10: fatal error: 'stringlist.h' file not found #include ^~~~~~~~~~~~~~ -./test-strlcat.c:7:12: warning: call to undeclared library function 'strlcat' with type 'unsigned long (char *, const char *, unsigned long)'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strlcat.c:7:12: error: call to undeclared library function 'strlcat' with type 'unsigned long (char *, const char *, unsigned long)'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return ! (strlcat(buf, "b", sizeof(buf)) == 2 && ^ ./test-strlcat.c:7:12: note: include the header or explicitly provide a declaration for 'strlcat' -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-strlcat-9da16a.o: in function `main': -test-strlcat.c:(.text+0x1f): undefined reference to `strlcat' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-strlcpy.c:7:12: warning: call to undeclared library function 'strlcpy' with type 'unsigned long (char *, const char *, unsigned long)'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strlcpy.c:7:12: error: call to undeclared library function 'strlcpy' with type 'unsigned long (char *, const char *, unsigned long)'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return ! (strlcpy(buf, "a", sizeof(buf)) == 1 && ^ ./test-strlcpy.c:7:12: note: include the header or explicitly provide a declaration for 'strlcpy' -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-strlcpy-b1fc4a.o: in function `main': -test-strlcpy.c:(.text+0x1a): undefined reference to `strlcpy' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-strptime.c:8:12: warning: call to undeclared function 'strptime'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strptime.c:8:12: error: call to undeclared function 'strptime'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return ! (strptime(input, "%Y-%m-%d", &tm) == input + 10 && ^ +./test-strptime.c:8:12: note: did you mean 'strftime'? +/usr/include/time.h:100:14: note: 'strftime' declared here +extern size_t strftime (char *__restrict __s, size_t __maxsize, + ^ ./test-strptime.c:8:45: error: comparison between pointer and integer ('int' and 'const char *') [-Werror,-Wpointer-integer-compare] return ! (strptime(input, "%Y-%m-%d", &tm) == input + 10 && ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~ +2 errors generated. -./test-strtonum.c:25:6: warning: call to undeclared function 'strtonum'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strtonum.c:25:6: error: call to undeclared function 'strtonum'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] if (strtonum("1", 0, 2, &errstr) != 1) ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-strtonum-14303d.o: in function `main': -test-strtonum.c:(.text+0x15): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x47): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x71): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x9e): undefined reference to `strtonum' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-strtonum.c:25:6: warning: call to undeclared function 'strtonum'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strtonum.c:25:6: error: call to undeclared function 'strtonum'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] if (strtonum("1", 0, 2, &errstr) != 1) ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-strtonum-1c7e20.o: in function `main': -test-strtonum.c:(.text+0x15): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x47): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x71): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x9e): undefined reference to `strtonum' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-vasprintf.c:32:8: warning: call to undeclared function 'vasprintf'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-vasprintf.c:32:8: error: call to undeclared function 'vasprintf'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] irc = vasprintf(ret, format, ap); ^ +./test-vasprintf.c:32:8: note: did you mean 'vsprintf'? +/usr/include/stdio.h:373:12: note: 'vsprintf' declared here +extern int vsprintf (char *__restrict __s, const char *__restrict __format, + ^ ./test-fts.c:24:34: error: incompatible function pointer types passing 'int (const FTSENT *const *, const FTSENT *const *)' (aka 'int (const struct _ftsent *const *, const struct _ftsent *const *)') to parameter of type 'int (*)(const FTSENT **, const FTSENT **)' (aka 'int (*)(const struct _ftsent **, const struct _ftsent **)') [-Werror,-Wincompatible-function-pointer-types] FTS_PHYSICAL | FTS_NOCHDIR, fts_compare); @@ -119,7 +115,7 @@ int (*)(const FTSENT **, const FTSENT **)); ^ -./test-wchar.c:46:15: warning: call to undeclared function 'wcwidth'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-wchar.c:46:14: error: call to undeclared function 'wcwidth'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] if ((width = wcwidth(L' ')) != 1) { ^ @@ -157,91 +153,87 @@ -./test-pledge.c:6:11: warning: call to undeclared function 'pledge'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-pledge.c:6:11: error: call to undeclared function 'pledge'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return !!pledge("stdio", NULL); ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-pledge-bc6c77.o: in function `main': -test-pledge.c:(.text+0xd): undefined reference to `pledge' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) ./test-sandbox_init.c:1:10: fatal error: 'sandbox.h' file not found #include ^~~~~~~~~~~ -./test-progname.c:8:13: warning: call to undeclared function 'getprogname'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-progname.c:8:13: error: call to undeclared function 'getprogname'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] progname = getprogname(); ^ ./test-progname.c:8:11: error: incompatible integer to pointer conversion assigning to 'const char *' from 'int' [-Wint-conversion] progname = getprogname(); ^ ~~~~~~~~~~~~~ +2 errors generated. -./test-recallocarray.c:10:10: warning: call to undeclared function 'recallocarray'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-recallocarray.c:10:10: error: call to undeclared function 'recallocarray'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return !recallocarray(p, 2, 3, 2); ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-recallocarray-6856c4.o: in function `main': -test-recallocarray.c:(.text+0x2a): undefined reference to `recallocarray' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-recallocarray.c:10:10: warning: call to undeclared function 'recallocarray'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-recallocarray.c:10:10: note: did you mean 'reallocarray'? +/usr/include/stdlib.h:569:14: note: 'reallocarray' declared here +extern void *reallocarray (void *__ptr, size_t __nmemb, size_t __size) + ^ +./test-recallocarray.c:10:10: error: call to undeclared function 'recallocarray'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return !recallocarray(p, 2, 3, 2); ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-recallocarray-ad5357.o: in function `main': -test-recallocarray.c:(.text+0x2a): undefined reference to `recallocarray' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) +./test-recallocarray.c:10:10: note: did you mean 'reallocarray'? +/usr/include/stdlib.h:569:14: note: 'reallocarray' declared here +extern void *reallocarray (void *__ptr, size_t __nmemb, size_t __size) + ^ -./test-strcasestr.c:7:13: warning: call to undeclared function 'strcasestr'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strcasestr.c:7:13: error: call to undeclared function 'strcasestr'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] char *cp = strcasestr(big, "Gst"); ^ +./test-strcasestr.c:7:13: note: did you mean 'strcasecmp'? +/usr/include/strings.h:116:12: note: 'strcasecmp' declared here +extern int strcasecmp (const char *__s1, const char *__s2) + ^ ./test-strcasestr.c:7:8: error: incompatible integer to pointer conversion initializing 'char *' with an expression of type 'int' [-Wint-conversion] char *cp = strcasestr(big, "Gst"); ^ ~~~~~~~~~~~~~~~~~~~~~~ +2 errors generated. ./test-stringlist.c:19:10: fatal error: 'stringlist.h' file not found #include ^~~~~~~~~~~~~~ -./test-strlcat.c:7:12: warning: call to undeclared library function 'strlcat' with type 'unsigned long (char *, const char *, unsigned long)'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strlcat.c:7:12: error: call to undeclared library function 'strlcat' with type 'unsigned long (char *, const char *, unsigned long)'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return ! (strlcat(buf, "b", sizeof(buf)) == 2 && ^ ./test-strlcat.c:7:12: note: include the header or explicitly provide a declaration for 'strlcat' -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-strlcat-9dcae4.o: in function `main': -test-strlcat.c:(.text+0x1f): undefined reference to `strlcat' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-strlcpy.c:7:12: warning: call to undeclared library function 'strlcpy' with type 'unsigned long (char *, const char *, unsigned long)'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strlcpy.c:7:12: error: call to undeclared library function 'strlcpy' with type 'unsigned long (char *, const char *, unsigned long)'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return ! (strlcpy(buf, "a", sizeof(buf)) == 1 && ^ ./test-strlcpy.c:7:12: note: include the header or explicitly provide a declaration for 'strlcpy' -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-strlcpy-c6e228.o: in function `main': -test-strlcpy.c:(.text+0x1a): undefined reference to `strlcpy' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-strptime.c:8:12: warning: call to undeclared function 'strptime'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strptime.c:8:12: error: call to undeclared function 'strptime'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] return ! (strptime(input, "%Y-%m-%d", &tm) == input + 10 && ^ +./test-strptime.c:8:12: note: did you mean 'strftime'? +/usr/include/time.h:100:14: note: 'strftime' declared here +extern size_t strftime (char *__restrict __s, size_t __maxsize, + ^ ./test-strptime.c:8:45: error: comparison between pointer and integer ('int' and 'const char *') [-Werror,-Wpointer-integer-compare] return ! (strptime(input, "%Y-%m-%d", &tm) == input + 10 && ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~ +2 errors generated. -./test-strtonum.c:25:6: warning: call to undeclared function 'strtonum'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strtonum.c:25:6: error: call to undeclared function 'strtonum'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] if (strtonum("1", 0, 2, &errstr) != 1) ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-strtonum-594c99.o: in function `main': -test-strtonum.c:(.text+0x15): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x47): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x71): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x9e): undefined reference to `strtonum' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-strtonum.c:25:6: warning: call to undeclared function 'strtonum'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-strtonum.c:25:6: error: call to undeclared function 'strtonum'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] if (strtonum("1", 0, 2, &errstr) != 1) ^ -/usr/bin/x86_64-pc-linux-gnu-ld: /var/tmp/portage/app-text/mandoc-1.14.6/temp/test-strtonum-c03f0d.o: in function `main': -test-strtonum.c:(.text+0x15): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x47): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x71): undefined reference to `strtonum' -/usr/bin/x86_64-pc-linux-gnu-ld: test-strtonum.c:(.text+0x9e): undefined reference to `strtonum' -clang-15: error: linker command failed with exit code 1 (use -v to see invocation) -./test-vasprintf.c:32:8: warning: call to undeclared function 'vasprintf'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-vasprintf.c:32:8: error: call to undeclared function 'vasprintf'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] irc = vasprintf(ret, format, ap); ^ +./test-vasprintf.c:32:8: note: did you mean 'vsprintf'? +/usr/include/stdio.h:373:12: note: 'vsprintf' declared here +extern int vsprintf (char *__restrict __s, const char *__restrict __format, + ^ ./test-fts.c:24:34: error: incompatible function pointer types passing 'int (const FTSENT *const *, const FTSENT *const *)' (aka 'int (const struct _ftsent *const *, const struct _ftsent *const *)') to parameter of type 'int (*)(const FTSENT **, const FTSENT **)' (aka 'int (*)(const struct _ftsent **, const struct _ftsent **)') [-Werror,-Wincompatible-function-pointer-types] FTS_PHYSICAL | FTS_NOCHDIR, fts_compare); @@ -250,7 +242,7 @@ int (*)(const FTSENT **, const FTSENT **)); ^ -./test-wchar.c:46:15: warning: call to undeclared function 'wcwidth'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] +./test-wchar.c:46:14: error: call to undeclared function 'wcwidth'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration] if ((width = wcwidth(L' ')) != 1) { ^