These patches - fix a compilation error of <unistr.h> and <unigbrk.h> in C++ mode, - add unit tests, so that this kind of mistake should never happen again.
2025-10-03 Bruno Haible <[email protected]> unimetadata/base: Add tests. * tests/unimetadata/test-unimetadata-h.c: New file. * modules/unimetadata/base-tests: New file. * tests/unimetadata/test-unimetadata-h-c++.cc: New file. * modules/unimetadata/base-c++-tests: New file. unicase/base: Add tests. * tests/unicase/test-unicase-h.c: New file. * modules/unicase/base-tests: New file. * tests/unicase/test-unicase-h-c++.cc: New file. * modules/unicase/base-c++-tests: New file. uninorm/base: Add tests. * tests/uninorm/test-uninorm-h.c: New file. * modules/uninorm/base-tests: New file. * tests/uninorm/test-uninorm-h-c++.cc: New file. * modules/uninorm/base-c++-tests: New file. unilbrk/base: Add tests. * tests/unilbrk/test-unilbrk-h.c: New file. * modules/unilbrk/base-tests: New file. * tests/unilbrk/test-unilbrk-h-c++.cc: New file. * modules/unilbrk/base-c++-tests: New file. uniwbrk/base: Add tests. * tests/uniwbrk/test-uniwbrk-h.c: New file. * modules/uniwbrk/base-tests: New file. * tests/uniwbrk/test-uniwbrk-h-c++.cc: New file. * modules/uniwbrk/base-c++-tests: New file. unigbrk/base: Add tests. * tests/unigbrk/test-unigbrk-h.c: New file. * modules/unigbrk/base-tests: New file. * tests/unigbrk/test-unigbrk-h-c++.cc: New file. * modules/unigbrk/base-c++-tests: New file. uniwidth/base: Add tests. * tests/uniwidth/test-uniwidth-h.c: New file. * modules/uniwidth/base-tests: New file. * tests/uniwidth/test-uniwidth-h-c++.cc: New file. * modules/uniwidth/base-c++-tests: New file. unictype/base: Add tests. * tests/unictype/test-unictype-h.c: New file. * modules/unictype/base-tests: New file. * tests/unictype/test-unictype-h-c++.cc: New file. * modules/unictype/base-c++-tests: New file. uniname/base: Add tests. * tests/uniname/test-uniname-h.c: New file. * modules/uniname/base-tests: New file. * tests/uniname/test-uniname-h-c++.cc: New file. * modules/uniname/base-c++-tests: New file. unistdio/base: Add tests. * tests/unistdio/test-unistdio-h.c: New file. * modules/unistdio/base-tests: New file. * tests/unistdio/test-unistdio-h-c++.cc: New file. * modules/unistdio/base-c++-tests: New file. uniconv/base: Add tests. * tests/uniconv/test-uniconv-h.c: New file. * modules/uniconv/base-tests: New file. * tests/uniconv/test-uniconv-h-c++.cc: New file. * modules/uniconv/base-c++-tests: New file. unistr/base: Add tests. * tests/unistr/test-unistr-h.c: New file. * modules/unistr/base-tests: New file. * tests/unistr/test-unistr-h-c++.cc: New file. * modules/unistr/base-c++-tests: New file. 2025-10-03 Bruno Haible <[email protected]> unistr, unigbrk: Fix compilation error in C++ mode (regr. 2025-02-09). Reported by Ryan Carsten Schmidt <[email protected]> at <https://savannah.gnu.org/bugs/?67576>. * lib/unistr.in.h (u*_check, u*_chr, u*_next, u*_prev, u*_strchr, u*_strrchr, u*_strpbrk, u*_strstr): Define C++ templates outside of 'extern "C"' block. * lib/unigbrk.in.h (u*_grapheme_next, u*_grapheme_prev): Likewise.
>From 3f2b934a627d29cbf9ef4d4fc3c63b46968a6312 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:13 +0200 Subject: [PATCH 01/13] unistr, unigbrk: Fix compilation error in C++ mode (regr. 2025-02-09). Reported by Ryan Carsten Schmidt <[email protected]> at <https://savannah.gnu.org/bugs/?67576>. * lib/unistr.in.h (u*_check, u*_chr, u*_next, u*_prev, u*_strchr, u*_strrchr, u*_strpbrk, u*_strstr): Define C++ templates outside of 'extern "C"' block. * lib/unigbrk.in.h (u*_grapheme_next, u*_grapheme_prev): Likewise. --- ChangeLog | 10 ++++++++++ lib/unigbrk.in.h | 12 ++++++++++++ lib/unistr.in.h | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 70 insertions(+) diff --git a/ChangeLog b/ChangeLog index b358ac895a..c24a3c46d2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2025-10-03 Bruno Haible <[email protected]> + + unistr, unigbrk: Fix compilation error in C++ mode (regr. 2025-02-09). + Reported by Ryan Carsten Schmidt <[email protected]> + at <https://savannah.gnu.org/bugs/?67576>. + * lib/unistr.in.h (u*_check, u*_chr, u*_next, u*_prev, u*_strchr, + u*_strrchr, u*_strpbrk, u*_strstr): Define C++ templates outside of + 'extern "C"' block. + * lib/unigbrk.in.h (u*_grapheme_next, u*_grapheme_prev): Likewise. + 2025-09-28 Collin Funk <[email protected]> xsetenv: Revert the previous change. diff --git a/lib/unigbrk.in.h b/lib/unigbrk.in.h index 0c474632b3..8a5c6051bb 100644 --- a/lib/unigbrk.in.h +++ b/lib/unigbrk.in.h @@ -111,6 +111,9 @@ extern const uint32_t * u32_grapheme_next (const uint32_t *s, const uint32_t *end) _UC_ATTRIBUTE_PURE; #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -176,6 +179,9 @@ template <> default : u32_grapheme_next ((s), (end))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Returns the start of the previous grapheme cluster before S, or NULL if the @@ -192,6 +198,9 @@ extern const uint32_t * u32_grapheme_prev (const uint32_t *s, const uint32_t *start) _UC_ATTRIBUTE_PURE; #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -257,6 +266,9 @@ template <> default : u32_grapheme_prev ((s), (start))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Determine the grapheme cluster boundaries in S, and store the result at diff --git a/lib/unistr.in.h b/lib/unistr.in.h index 42aea40e7e..4b80b1610d 100644 --- a/lib/unistr.in.h +++ b/lib/unistr.in.h @@ -82,6 +82,9 @@ extern const uint32_t * _UC_ATTRIBUTE_PURE; #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -147,6 +150,9 @@ template <> default : u32_check ((s), (n))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif @@ -513,6 +519,9 @@ extern uint32_t * u32_chr (const uint32_t *s, size_t n, ucs4_t uc) _UC_ATTRIBUTE_PURE; #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -578,6 +587,9 @@ template <> default : u32_chr ((s), (n), (u))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Count the number of Unicode characters in the N units from S. */ @@ -636,6 +648,9 @@ extern const uint16_t * extern const uint32_t * u32_next (ucs4_t *puc, const uint32_t *s); #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -701,6 +716,9 @@ template <> default : u32_next ((p), (s))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Backward iteration step. Advances the pointer to point to the previous @@ -713,6 +731,9 @@ extern const uint16_t * extern const uint32_t * u32_prev (ucs4_t *puc, const uint32_t *s, const uint32_t *start); #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -778,6 +799,9 @@ template <> default : u32_prev ((p), (s), (start))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Return the number of units in S. */ @@ -926,6 +950,9 @@ extern uint32_t * u32_strchr (const uint32_t *str, ucs4_t uc) _UC_ATTRIBUTE_PURE; #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -991,6 +1018,9 @@ template <> default : u32_strchr ((s), (u))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Find the last occurrence of UC in STR. */ @@ -1005,6 +1035,9 @@ extern uint32_t * u32_strrchr (const uint32_t *str, ucs4_t uc) _UC_ATTRIBUTE_PURE; #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -1070,6 +1103,9 @@ template <> default : u32_strrchr ((s), (u))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Return the length of the initial segment of STR which consists entirely @@ -1110,6 +1146,9 @@ extern uint32_t * u32_strpbrk (const uint32_t *str, const uint32_t *accept) _UC_ATTRIBUTE_PURE; #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -1175,6 +1214,9 @@ template <> default : u32_strpbrk ((s), (a))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Find the first occurrence of NEEDLE in HAYSTACK. */ @@ -1189,6 +1231,9 @@ extern uint32_t * u32_strstr (const uint32_t *haystack, const uint32_t *needle) _UC_ATTRIBUTE_PURE; #ifndef _LIBUNISTRING_NO_CONST_GENERICS +# ifdef __cplusplus +} +# endif /* Don't silently convert a 'const uintN_t *' to a 'uintN_t *'. Programmers want compiler warnings for 'const' related mistakes. */ # ifdef __cplusplus @@ -1254,6 +1299,9 @@ template <> default : u32_strstr ((h), (n))) # endif # endif +# ifdef __cplusplus +extern "C" { +# endif #endif /* Test whether STR starts with PREFIX. */ -- 2.51.0
>From 8077cba5bc67970d7a783c203ab07ed085f9267a Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:29 +0200 Subject: [PATCH 02/13] unistr/base: Add tests. * tests/unistr/test-unistr-h.c: New file. * modules/unistr/base-tests: New file. * tests/unistr/test-unistr-h-c++.cc: New file. * modules/unistr/base-c++-tests: New file. --- ChangeLog | 8 ++++++++ modules/unistr/base-c++-tests | 18 ++++++++++++++++++ modules/unistr/base-tests | 13 +++++++++++++ tests/unistr/test-unistr-h-c++.cc | 25 +++++++++++++++++++++++++ tests/unistr/test-unistr-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 90 insertions(+) create mode 100644 modules/unistr/base-c++-tests create mode 100644 modules/unistr/base-tests create mode 100644 tests/unistr/test-unistr-h-c++.cc create mode 100644 tests/unistr/test-unistr-h.c diff --git a/ChangeLog b/ChangeLog index c24a3c46d2..11a5fd25af 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2025-10-03 Bruno Haible <[email protected]> + + unistr/base: Add tests. + * tests/unistr/test-unistr-h.c: New file. + * modules/unistr/base-tests: New file. + * tests/unistr/test-unistr-h-c++.cc: New file. + * modules/unistr/base-c++-tests: New file. + 2025-10-03 Bruno Haible <[email protected]> unistr, unigbrk: Fix compilation error in C++ mode (regr. 2025-02-09). diff --git a/modules/unistr/base-c++-tests b/modules/unistr/base-c++-tests new file mode 100644 index 0000000000..e87108d825 --- /dev/null +++ b/modules/unistr/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/unistr/test-unistr-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-unistr-h-c++ +check_PROGRAMS += test-unistr-h-c++ +test_unistr_h_c___SOURCES = unistr/test-unistr-h-c++.cc +test_unistr_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/unistr/base-tests b/modules/unistr/base-tests new file mode 100644 index 0000000000..68fa61886e --- /dev/null +++ b/modules/unistr/base-tests @@ -0,0 +1,13 @@ +Files: +tests/unistr/test-unistr-h.c + +Depends-on: +unistr/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-unistr-h +check_PROGRAMS += test-unistr-h +test_unistr_h_SOURCES = unistr/test-unistr-h.c +test_unistr_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/unistr/test-unistr-h-c++.cc b/tests/unistr/test-unistr-h-c++.cc new file mode 100644 index 0000000000..507c3d7179 --- /dev/null +++ b/tests/unistr/test-unistr-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <unistr.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unistr.h> + +int +main () +{ +} diff --git a/tests/unistr/test-unistr-h.c b/tests/unistr/test-unistr-h.c new file mode 100644 index 0000000000..085fcac567 --- /dev/null +++ b/tests/unistr/test-unistr-h.c @@ -0,0 +1,26 @@ +/* Test of <unistr.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unistr.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From 068652f6c472bf9d9bf00764d8486e24e43dae74 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:42 +0200 Subject: [PATCH 03/13] uniconv/base: Add tests. * tests/uniconv/test-uniconv-h.c: New file. * modules/uniconv/base-tests: New file. * tests/uniconv/test-uniconv-h-c++.cc: New file. * modules/uniconv/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/uniconv/base-c++-tests | 18 ++++++++++++++++++ modules/uniconv/base-tests | 13 +++++++++++++ tests/uniconv/test-uniconv-h-c++.cc | 25 +++++++++++++++++++++++++ tests/uniconv/test-uniconv-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/uniconv/base-c++-tests create mode 100644 modules/uniconv/base-tests create mode 100644 tests/uniconv/test-uniconv-h-c++.cc create mode 100644 tests/uniconv/test-uniconv-h.c diff --git a/ChangeLog b/ChangeLog index 11a5fd25af..88f1bf46c5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + uniconv/base: Add tests. + * tests/uniconv/test-uniconv-h.c: New file. + * modules/uniconv/base-tests: New file. + * tests/uniconv/test-uniconv-h-c++.cc: New file. + * modules/uniconv/base-c++-tests: New file. + unistr/base: Add tests. * tests/unistr/test-unistr-h.c: New file. * modules/unistr/base-tests: New file. diff --git a/modules/uniconv/base-c++-tests b/modules/uniconv/base-c++-tests new file mode 100644 index 0000000000..fcb6883a8e --- /dev/null +++ b/modules/uniconv/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/uniconv/test-uniconv-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-uniconv-h-c++ +check_PROGRAMS += test-uniconv-h-c++ +test_uniconv_h_c___SOURCES = uniconv/test-uniconv-h-c++.cc +test_uniconv_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/uniconv/base-tests b/modules/uniconv/base-tests new file mode 100644 index 0000000000..00067a3fa1 --- /dev/null +++ b/modules/uniconv/base-tests @@ -0,0 +1,13 @@ +Files: +tests/uniconv/test-uniconv-h.c + +Depends-on: +uniconv/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-uniconv-h +check_PROGRAMS += test-uniconv-h +test_uniconv_h_SOURCES = uniconv/test-uniconv-h.c +test_uniconv_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/uniconv/test-uniconv-h-c++.cc b/tests/uniconv/test-uniconv-h-c++.cc new file mode 100644 index 0000000000..988eb61729 --- /dev/null +++ b/tests/uniconv/test-uniconv-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <uniconv.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uniconv.h> + +int +main () +{ +} diff --git a/tests/uniconv/test-uniconv-h.c b/tests/uniconv/test-uniconv-h.c new file mode 100644 index 0000000000..150cbe73ba --- /dev/null +++ b/tests/uniconv/test-uniconv-h.c @@ -0,0 +1,26 @@ +/* Test of <uniconv.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uniconv.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From 82c4f2b9e9142f1e035fcd7078cc2bae64311337 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:46 +0200 Subject: [PATCH 04/13] unistdio/base: Add tests. * tests/unistdio/test-unistdio-h.c: New file. * modules/unistdio/base-tests: New file. * tests/unistdio/test-unistdio-h-c++.cc: New file. * modules/unistdio/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/unistdio/base-c++-tests | 18 ++++++++++++++++++ modules/unistdio/base-tests | 13 +++++++++++++ tests/unistdio/test-unistdio-h-c++.cc | 25 +++++++++++++++++++++++++ tests/unistdio/test-unistdio-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/unistdio/base-c++-tests create mode 100644 modules/unistdio/base-tests create mode 100644 tests/unistdio/test-unistdio-h-c++.cc create mode 100644 tests/unistdio/test-unistdio-h.c diff --git a/ChangeLog b/ChangeLog index 88f1bf46c5..31438cc046 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + unistdio/base: Add tests. + * tests/unistdio/test-unistdio-h.c: New file. + * modules/unistdio/base-tests: New file. + * tests/unistdio/test-unistdio-h-c++.cc: New file. + * modules/unistdio/base-c++-tests: New file. + uniconv/base: Add tests. * tests/uniconv/test-uniconv-h.c: New file. * modules/uniconv/base-tests: New file. diff --git a/modules/unistdio/base-c++-tests b/modules/unistdio/base-c++-tests new file mode 100644 index 0000000000..f98cf4ffe3 --- /dev/null +++ b/modules/unistdio/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/unistdio/test-unistdio-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-unistdio-h-c++ +check_PROGRAMS += test-unistdio-h-c++ +test_unistdio_h_c___SOURCES = unistdio/test-unistdio-h-c++.cc +test_unistdio_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/unistdio/base-tests b/modules/unistdio/base-tests new file mode 100644 index 0000000000..9bdfc9c0d5 --- /dev/null +++ b/modules/unistdio/base-tests @@ -0,0 +1,13 @@ +Files: +tests/unistdio/test-unistdio-h.c + +Depends-on: +unistdio/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-unistdio-h +check_PROGRAMS += test-unistdio-h +test_unistdio_h_SOURCES = unistdio/test-unistdio-h.c +test_unistdio_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/unistdio/test-unistdio-h-c++.cc b/tests/unistdio/test-unistdio-h-c++.cc new file mode 100644 index 0000000000..47c6cbdef9 --- /dev/null +++ b/tests/unistdio/test-unistdio-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <unistdio.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unistdio.h> + +int +main () +{ +} diff --git a/tests/unistdio/test-unistdio-h.c b/tests/unistdio/test-unistdio-h.c new file mode 100644 index 0000000000..b5a085d219 --- /dev/null +++ b/tests/unistdio/test-unistdio-h.c @@ -0,0 +1,26 @@ +/* Test of <unistdio.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unistdio.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From 1d10a39553e883a70e0f2a3e7ccd66ae33aea8c1 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:48 +0200 Subject: [PATCH 05/13] uniname/base: Add tests. * tests/uniname/test-uniname-h.c: New file. * modules/uniname/base-tests: New file. * tests/uniname/test-uniname-h-c++.cc: New file. * modules/uniname/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/uniname/base-c++-tests | 18 ++++++++++++++++++ modules/uniname/base-tests | 13 +++++++++++++ tests/uniname/test-uniname-h-c++.cc | 25 +++++++++++++++++++++++++ tests/uniname/test-uniname-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/uniname/base-c++-tests create mode 100644 modules/uniname/base-tests create mode 100644 tests/uniname/test-uniname-h-c++.cc create mode 100644 tests/uniname/test-uniname-h.c diff --git a/ChangeLog b/ChangeLog index 31438cc046..18e997945f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + uniname/base: Add tests. + * tests/uniname/test-uniname-h.c: New file. + * modules/uniname/base-tests: New file. + * tests/uniname/test-uniname-h-c++.cc: New file. + * modules/uniname/base-c++-tests: New file. + unistdio/base: Add tests. * tests/unistdio/test-unistdio-h.c: New file. * modules/unistdio/base-tests: New file. diff --git a/modules/uniname/base-c++-tests b/modules/uniname/base-c++-tests new file mode 100644 index 0000000000..769ca7ee7a --- /dev/null +++ b/modules/uniname/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/uniname/test-uniname-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-uniname-h-c++ +check_PROGRAMS += test-uniname-h-c++ +test_uniname_h_c___SOURCES = uniname/test-uniname-h-c++.cc +test_uniname_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/uniname/base-tests b/modules/uniname/base-tests new file mode 100644 index 0000000000..8438b660ef --- /dev/null +++ b/modules/uniname/base-tests @@ -0,0 +1,13 @@ +Files: +tests/uniname/test-uniname-h.c + +Depends-on: +uniname/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-uniname-h +check_PROGRAMS += test-uniname-h +test_uniname_h_SOURCES = uniname/test-uniname-h.c +test_uniname_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/uniname/test-uniname-h-c++.cc b/tests/uniname/test-uniname-h-c++.cc new file mode 100644 index 0000000000..abdb341701 --- /dev/null +++ b/tests/uniname/test-uniname-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <uniname.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uniname.h> + +int +main () +{ +} diff --git a/tests/uniname/test-uniname-h.c b/tests/uniname/test-uniname-h.c new file mode 100644 index 0000000000..4ad982ac3a --- /dev/null +++ b/tests/uniname/test-uniname-h.c @@ -0,0 +1,26 @@ +/* Test of <uniname.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uniname.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From b2ad9004ced6ef893d107d0c20dd3d92b94a593e Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:51 +0200 Subject: [PATCH 06/13] unictype/base: Add tests. * tests/unictype/test-unictype-h.c: New file. * modules/unictype/base-tests: New file. * tests/unictype/test-unictype-h-c++.cc: New file. * modules/unictype/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/unictype/base-c++-tests | 18 ++++++++++++++++++ modules/unictype/base-tests | 13 +++++++++++++ tests/unictype/test-unictype-h-c++.cc | 25 +++++++++++++++++++++++++ tests/unictype/test-unictype-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/unictype/base-c++-tests create mode 100644 modules/unictype/base-tests create mode 100644 tests/unictype/test-unictype-h-c++.cc create mode 100644 tests/unictype/test-unictype-h.c diff --git a/ChangeLog b/ChangeLog index 18e997945f..be64434def 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + unictype/base: Add tests. + * tests/unictype/test-unictype-h.c: New file. + * modules/unictype/base-tests: New file. + * tests/unictype/test-unictype-h-c++.cc: New file. + * modules/unictype/base-c++-tests: New file. + uniname/base: Add tests. * tests/uniname/test-uniname-h.c: New file. * modules/uniname/base-tests: New file. diff --git a/modules/unictype/base-c++-tests b/modules/unictype/base-c++-tests new file mode 100644 index 0000000000..cea45797c5 --- /dev/null +++ b/modules/unictype/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/unictype/test-unictype-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-unictype-h-c++ +check_PROGRAMS += test-unictype-h-c++ +test_unictype_h_c___SOURCES = unictype/test-unictype-h-c++.cc +test_unictype_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/unictype/base-tests b/modules/unictype/base-tests new file mode 100644 index 0000000000..88d8c3751d --- /dev/null +++ b/modules/unictype/base-tests @@ -0,0 +1,13 @@ +Files: +tests/unictype/test-unictype-h.c + +Depends-on: +unictype/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-unictype-h +check_PROGRAMS += test-unictype-h +test_unictype_h_SOURCES = unictype/test-unictype-h.c +test_unictype_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/unictype/test-unictype-h-c++.cc b/tests/unictype/test-unictype-h-c++.cc new file mode 100644 index 0000000000..b86b9f0e86 --- /dev/null +++ b/tests/unictype/test-unictype-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <unictype.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unictype.h> + +int +main () +{ +} diff --git a/tests/unictype/test-unictype-h.c b/tests/unictype/test-unictype-h.c new file mode 100644 index 0000000000..b1f07c997b --- /dev/null +++ b/tests/unictype/test-unictype-h.c @@ -0,0 +1,26 @@ +/* Test of <unictype.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unictype.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From 65b2a8bacf14cd70346239389b166434402fb489 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:53 +0200 Subject: [PATCH 07/13] uniwidth/base: Add tests. * tests/uniwidth/test-uniwidth-h.c: New file. * modules/uniwidth/base-tests: New file. * tests/uniwidth/test-uniwidth-h-c++.cc: New file. * modules/uniwidth/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/uniwidth/base-c++-tests | 18 ++++++++++++++++++ modules/uniwidth/base-tests | 13 +++++++++++++ tests/uniwidth/test-uniwidth-h-c++.cc | 25 +++++++++++++++++++++++++ tests/uniwidth/test-uniwidth-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/uniwidth/base-c++-tests create mode 100644 modules/uniwidth/base-tests create mode 100644 tests/uniwidth/test-uniwidth-h-c++.cc create mode 100644 tests/uniwidth/test-uniwidth-h.c diff --git a/ChangeLog b/ChangeLog index be64434def..abbe399c76 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + uniwidth/base: Add tests. + * tests/uniwidth/test-uniwidth-h.c: New file. + * modules/uniwidth/base-tests: New file. + * tests/uniwidth/test-uniwidth-h-c++.cc: New file. + * modules/uniwidth/base-c++-tests: New file. + unictype/base: Add tests. * tests/unictype/test-unictype-h.c: New file. * modules/unictype/base-tests: New file. diff --git a/modules/uniwidth/base-c++-tests b/modules/uniwidth/base-c++-tests new file mode 100644 index 0000000000..a0021c6e17 --- /dev/null +++ b/modules/uniwidth/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/uniwidth/test-uniwidth-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-uniwidth-h-c++ +check_PROGRAMS += test-uniwidth-h-c++ +test_uniwidth_h_c___SOURCES = uniwidth/test-uniwidth-h-c++.cc +test_uniwidth_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/uniwidth/base-tests b/modules/uniwidth/base-tests new file mode 100644 index 0000000000..d55cf5007c --- /dev/null +++ b/modules/uniwidth/base-tests @@ -0,0 +1,13 @@ +Files: +tests/uniwidth/test-uniwidth-h.c + +Depends-on: +uniwidth/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-uniwidth-h +check_PROGRAMS += test-uniwidth-h +test_uniwidth_h_SOURCES = uniwidth/test-uniwidth-h.c +test_uniwidth_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/uniwidth/test-uniwidth-h-c++.cc b/tests/uniwidth/test-uniwidth-h-c++.cc new file mode 100644 index 0000000000..6823884369 --- /dev/null +++ b/tests/uniwidth/test-uniwidth-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <uniwidth.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uniwidth.h> + +int +main () +{ +} diff --git a/tests/uniwidth/test-uniwidth-h.c b/tests/uniwidth/test-uniwidth-h.c new file mode 100644 index 0000000000..74f1d6adb7 --- /dev/null +++ b/tests/uniwidth/test-uniwidth-h.c @@ -0,0 +1,26 @@ +/* Test of <uniwidth.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uniwidth.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From c3551bcaedf6be16b6726eca5aa56144cfa044d5 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:56 +0200 Subject: [PATCH 08/13] unigbrk/base: Add tests. * tests/unigbrk/test-unigbrk-h.c: New file. * modules/unigbrk/base-tests: New file. * tests/unigbrk/test-unigbrk-h-c++.cc: New file. * modules/unigbrk/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/unigbrk/base-c++-tests | 18 ++++++++++++++++++ modules/unigbrk/base-tests | 13 +++++++++++++ tests/unigbrk/test-unigbrk-h-c++.cc | 25 +++++++++++++++++++++++++ tests/unigbrk/test-unigbrk-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/unigbrk/base-c++-tests create mode 100644 modules/unigbrk/base-tests create mode 100644 tests/unigbrk/test-unigbrk-h-c++.cc create mode 100644 tests/unigbrk/test-unigbrk-h.c diff --git a/ChangeLog b/ChangeLog index abbe399c76..1b7c584bf7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + unigbrk/base: Add tests. + * tests/unigbrk/test-unigbrk-h.c: New file. + * modules/unigbrk/base-tests: New file. + * tests/unigbrk/test-unigbrk-h-c++.cc: New file. + * modules/unigbrk/base-c++-tests: New file. + uniwidth/base: Add tests. * tests/uniwidth/test-uniwidth-h.c: New file. * modules/uniwidth/base-tests: New file. diff --git a/modules/unigbrk/base-c++-tests b/modules/unigbrk/base-c++-tests new file mode 100644 index 0000000000..5c2d6932cc --- /dev/null +++ b/modules/unigbrk/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/unigbrk/test-unigbrk-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-unigbrk-h-c++ +check_PROGRAMS += test-unigbrk-h-c++ +test_unigbrk_h_c___SOURCES = unigbrk/test-unigbrk-h-c++.cc +test_unigbrk_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/unigbrk/base-tests b/modules/unigbrk/base-tests new file mode 100644 index 0000000000..079a474e47 --- /dev/null +++ b/modules/unigbrk/base-tests @@ -0,0 +1,13 @@ +Files: +tests/unigbrk/test-unigbrk-h.c + +Depends-on: +unigbrk/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-unigbrk-h +check_PROGRAMS += test-unigbrk-h +test_unigbrk_h_SOURCES = unigbrk/test-unigbrk-h.c +test_unigbrk_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/unigbrk/test-unigbrk-h-c++.cc b/tests/unigbrk/test-unigbrk-h-c++.cc new file mode 100644 index 0000000000..2e79602c9a --- /dev/null +++ b/tests/unigbrk/test-unigbrk-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <unigbrk.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unigbrk.h> + +int +main () +{ +} diff --git a/tests/unigbrk/test-unigbrk-h.c b/tests/unigbrk/test-unigbrk-h.c new file mode 100644 index 0000000000..4058f25229 --- /dev/null +++ b/tests/unigbrk/test-unigbrk-h.c @@ -0,0 +1,26 @@ +/* Test of <unigbrk.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unigbrk.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From 3cd44d44b2a8515f109f484133bb18592be17607 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:50:59 +0200 Subject: [PATCH 09/13] uniwbrk/base: Add tests. * tests/uniwbrk/test-uniwbrk-h.c: New file. * modules/uniwbrk/base-tests: New file. * tests/uniwbrk/test-uniwbrk-h-c++.cc: New file. * modules/uniwbrk/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/uniwbrk/base-c++-tests | 18 ++++++++++++++++++ modules/uniwbrk/base-tests | 13 +++++++++++++ tests/uniwbrk/test-uniwbrk-h-c++.cc | 25 +++++++++++++++++++++++++ tests/uniwbrk/test-uniwbrk-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/uniwbrk/base-c++-tests create mode 100644 modules/uniwbrk/base-tests create mode 100644 tests/uniwbrk/test-uniwbrk-h-c++.cc create mode 100644 tests/uniwbrk/test-uniwbrk-h.c diff --git a/ChangeLog b/ChangeLog index 1b7c584bf7..0bfeb47260 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + uniwbrk/base: Add tests. + * tests/uniwbrk/test-uniwbrk-h.c: New file. + * modules/uniwbrk/base-tests: New file. + * tests/uniwbrk/test-uniwbrk-h-c++.cc: New file. + * modules/uniwbrk/base-c++-tests: New file. + unigbrk/base: Add tests. * tests/unigbrk/test-unigbrk-h.c: New file. * modules/unigbrk/base-tests: New file. diff --git a/modules/uniwbrk/base-c++-tests b/modules/uniwbrk/base-c++-tests new file mode 100644 index 0000000000..764fb3f453 --- /dev/null +++ b/modules/uniwbrk/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/uniwbrk/test-uniwbrk-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-uniwbrk-h-c++ +check_PROGRAMS += test-uniwbrk-h-c++ +test_uniwbrk_h_c___SOURCES = uniwbrk/test-uniwbrk-h-c++.cc +test_uniwbrk_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/uniwbrk/base-tests b/modules/uniwbrk/base-tests new file mode 100644 index 0000000000..22367718fe --- /dev/null +++ b/modules/uniwbrk/base-tests @@ -0,0 +1,13 @@ +Files: +tests/uniwbrk/test-uniwbrk-h.c + +Depends-on: +uniwbrk/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-uniwbrk-h +check_PROGRAMS += test-uniwbrk-h +test_uniwbrk_h_SOURCES = uniwbrk/test-uniwbrk-h.c +test_uniwbrk_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/uniwbrk/test-uniwbrk-h-c++.cc b/tests/uniwbrk/test-uniwbrk-h-c++.cc new file mode 100644 index 0000000000..bc6b053374 --- /dev/null +++ b/tests/uniwbrk/test-uniwbrk-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <uniwbrk.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uniwbrk.h> + +int +main () +{ +} diff --git a/tests/uniwbrk/test-uniwbrk-h.c b/tests/uniwbrk/test-uniwbrk-h.c new file mode 100644 index 0000000000..7954b894d2 --- /dev/null +++ b/tests/uniwbrk/test-uniwbrk-h.c @@ -0,0 +1,26 @@ +/* Test of <uniwbrk.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uniwbrk.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From 69db3cfd80211e808c88e23bfdafa96572ad3edc Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:51:01 +0200 Subject: [PATCH 10/13] unilbrk/base: Add tests. * tests/unilbrk/test-unilbrk-h.c: New file. * modules/unilbrk/base-tests: New file. * tests/unilbrk/test-unilbrk-h-c++.cc: New file. * modules/unilbrk/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/unilbrk/base-c++-tests | 18 ++++++++++++++++++ modules/unilbrk/base-tests | 13 +++++++++++++ tests/unilbrk/test-unilbrk-h-c++.cc | 25 +++++++++++++++++++++++++ tests/unilbrk/test-unilbrk-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/unilbrk/base-c++-tests create mode 100644 modules/unilbrk/base-tests create mode 100644 tests/unilbrk/test-unilbrk-h-c++.cc create mode 100644 tests/unilbrk/test-unilbrk-h.c diff --git a/ChangeLog b/ChangeLog index 0bfeb47260..95af443f94 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + unilbrk/base: Add tests. + * tests/unilbrk/test-unilbrk-h.c: New file. + * modules/unilbrk/base-tests: New file. + * tests/unilbrk/test-unilbrk-h-c++.cc: New file. + * modules/unilbrk/base-c++-tests: New file. + uniwbrk/base: Add tests. * tests/uniwbrk/test-uniwbrk-h.c: New file. * modules/uniwbrk/base-tests: New file. diff --git a/modules/unilbrk/base-c++-tests b/modules/unilbrk/base-c++-tests new file mode 100644 index 0000000000..2369f3258b --- /dev/null +++ b/modules/unilbrk/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/unilbrk/test-unilbrk-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-unilbrk-h-c++ +check_PROGRAMS += test-unilbrk-h-c++ +test_unilbrk_h_c___SOURCES = unilbrk/test-unilbrk-h-c++.cc +test_unilbrk_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/unilbrk/base-tests b/modules/unilbrk/base-tests new file mode 100644 index 0000000000..f3171b8505 --- /dev/null +++ b/modules/unilbrk/base-tests @@ -0,0 +1,13 @@ +Files: +tests/unilbrk/test-unilbrk-h.c + +Depends-on: +unilbrk/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-unilbrk-h +check_PROGRAMS += test-unilbrk-h +test_unilbrk_h_SOURCES = unilbrk/test-unilbrk-h.c +test_unilbrk_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/unilbrk/test-unilbrk-h-c++.cc b/tests/unilbrk/test-unilbrk-h-c++.cc new file mode 100644 index 0000000000..d1459a2517 --- /dev/null +++ b/tests/unilbrk/test-unilbrk-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <unilbrk.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unilbrk.h> + +int +main () +{ +} diff --git a/tests/unilbrk/test-unilbrk-h.c b/tests/unilbrk/test-unilbrk-h.c new file mode 100644 index 0000000000..c06cbeeb2c --- /dev/null +++ b/tests/unilbrk/test-unilbrk-h.c @@ -0,0 +1,26 @@ +/* Test of <unilbrk.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unilbrk.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From fde8832abbbc6fd8661d2a83fc74f796a65b6457 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:51:05 +0200 Subject: [PATCH 11/13] uninorm/base: Add tests. * tests/uninorm/test-uninorm-h.c: New file. * modules/uninorm/base-tests: New file. * tests/uninorm/test-uninorm-h-c++.cc: New file. * modules/uninorm/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/uninorm/base-c++-tests | 18 ++++++++++++++++++ modules/uninorm/base-tests | 13 +++++++++++++ tests/uninorm/test-uninorm-h-c++.cc | 25 +++++++++++++++++++++++++ tests/uninorm/test-uninorm-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/uninorm/base-c++-tests create mode 100644 modules/uninorm/base-tests create mode 100644 tests/uninorm/test-uninorm-h-c++.cc create mode 100644 tests/uninorm/test-uninorm-h.c diff --git a/ChangeLog b/ChangeLog index 95af443f94..0e97674ffe 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + uninorm/base: Add tests. + * tests/uninorm/test-uninorm-h.c: New file. + * modules/uninorm/base-tests: New file. + * tests/uninorm/test-uninorm-h-c++.cc: New file. + * modules/uninorm/base-c++-tests: New file. + unilbrk/base: Add tests. * tests/unilbrk/test-unilbrk-h.c: New file. * modules/unilbrk/base-tests: New file. diff --git a/modules/uninorm/base-c++-tests b/modules/uninorm/base-c++-tests new file mode 100644 index 0000000000..d392eb735b --- /dev/null +++ b/modules/uninorm/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/uninorm/test-uninorm-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-uninorm-h-c++ +check_PROGRAMS += test-uninorm-h-c++ +test_uninorm_h_c___SOURCES = uninorm/test-uninorm-h-c++.cc +test_uninorm_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/uninorm/base-tests b/modules/uninorm/base-tests new file mode 100644 index 0000000000..8bb7cb7b46 --- /dev/null +++ b/modules/uninorm/base-tests @@ -0,0 +1,13 @@ +Files: +tests/uninorm/test-uninorm-h.c + +Depends-on: +uninorm/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-uninorm-h +check_PROGRAMS += test-uninorm-h +test_uninorm_h_SOURCES = uninorm/test-uninorm-h.c +test_uninorm_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/uninorm/test-uninorm-h-c++.cc b/tests/uninorm/test-uninorm-h-c++.cc new file mode 100644 index 0000000000..79fbe51673 --- /dev/null +++ b/tests/uninorm/test-uninorm-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <uninorm.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uninorm.h> + +int +main () +{ +} diff --git a/tests/uninorm/test-uninorm-h.c b/tests/uninorm/test-uninorm-h.c new file mode 100644 index 0000000000..0398d24ec4 --- /dev/null +++ b/tests/uninorm/test-uninorm-h.c @@ -0,0 +1,26 @@ +/* Test of <uninorm.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <uninorm.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From 268c44d1e359e3debfcee5f484c9ea786bbd2780 Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:51:08 +0200 Subject: [PATCH 12/13] unicase/base: Add tests. * tests/unicase/test-unicase-h.c: New file. * modules/unicase/base-tests: New file. * tests/unicase/test-unicase-h-c++.cc: New file. * modules/unicase/base-c++-tests: New file. --- ChangeLog | 6 ++++++ modules/unicase/base-c++-tests | 18 ++++++++++++++++++ modules/unicase/base-tests | 13 +++++++++++++ tests/unicase/test-unicase-h-c++.cc | 25 +++++++++++++++++++++++++ tests/unicase/test-unicase-h.c | 26 ++++++++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/unicase/base-c++-tests create mode 100644 modules/unicase/base-tests create mode 100644 tests/unicase/test-unicase-h-c++.cc create mode 100644 tests/unicase/test-unicase-h.c diff --git a/ChangeLog b/ChangeLog index 0e97674ffe..e73f7acdcf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + unicase/base: Add tests. + * tests/unicase/test-unicase-h.c: New file. + * modules/unicase/base-tests: New file. + * tests/unicase/test-unicase-h-c++.cc: New file. + * modules/unicase/base-c++-tests: New file. + uninorm/base: Add tests. * tests/uninorm/test-uninorm-h.c: New file. * modules/uninorm/base-tests: New file. diff --git a/modules/unicase/base-c++-tests b/modules/unicase/base-c++-tests new file mode 100644 index 0000000000..69d35433b9 --- /dev/null +++ b/modules/unicase/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/unicase/test-unicase-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-unicase-h-c++ +check_PROGRAMS += test-unicase-h-c++ +test_unicase_h_c___SOURCES = unicase/test-unicase-h-c++.cc +test_unicase_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/unicase/base-tests b/modules/unicase/base-tests new file mode 100644 index 0000000000..09e9fef82d --- /dev/null +++ b/modules/unicase/base-tests @@ -0,0 +1,13 @@ +Files: +tests/unicase/test-unicase-h.c + +Depends-on: +unicase/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-unicase-h +check_PROGRAMS += test-unicase-h +test_unicase_h_SOURCES = unicase/test-unicase-h.c +test_unicase_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/unicase/test-unicase-h-c++.cc b/tests/unicase/test-unicase-h-c++.cc new file mode 100644 index 0000000000..27208cc7c7 --- /dev/null +++ b/tests/unicase/test-unicase-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <unicase.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unicase.h> + +int +main () +{ +} diff --git a/tests/unicase/test-unicase-h.c b/tests/unicase/test-unicase-h.c new file mode 100644 index 0000000000..b09e0f050a --- /dev/null +++ b/tests/unicase/test-unicase-h.c @@ -0,0 +1,26 @@ +/* Test of <unicase.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unicase.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
>From e0bcc7d66e9f29cc1fb4abf50da1f5e525824e7e Mon Sep 17 00:00:00 2001 From: Bruno Haible <[email protected]> Date: Fri, 3 Oct 2025 21:51:11 +0200 Subject: [PATCH 13/13] unimetadata/base: Add tests. * tests/unimetadata/test-unimetadata-h.c: New file. * modules/unimetadata/base-tests: New file. * tests/unimetadata/test-unimetadata-h-c++.cc: New file. * modules/unimetadata/base-c++-tests: New file. --- ChangeLog | 6 +++++ modules/unimetadata/base-c++-tests | 18 ++++++++++++++ modules/unimetadata/base-tests | 13 +++++++++++ tests/unimetadata/test-unimetadata-h-c++.cc | 25 ++++++++++++++++++++ tests/unimetadata/test-unimetadata-h.c | 26 +++++++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 modules/unimetadata/base-c++-tests create mode 100644 modules/unimetadata/base-tests create mode 100644 tests/unimetadata/test-unimetadata-h-c++.cc create mode 100644 tests/unimetadata/test-unimetadata-h.c diff --git a/ChangeLog b/ChangeLog index e73f7acdcf..325ef7d087 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2025-10-03 Bruno Haible <[email protected]> + unimetadata/base: Add tests. + * tests/unimetadata/test-unimetadata-h.c: New file. + * modules/unimetadata/base-tests: New file. + * tests/unimetadata/test-unimetadata-h-c++.cc: New file. + * modules/unimetadata/base-c++-tests: New file. + unicase/base: Add tests. * tests/unicase/test-unicase-h.c: New file. * modules/unicase/base-tests: New file. diff --git a/modules/unimetadata/base-c++-tests b/modules/unimetadata/base-c++-tests new file mode 100644 index 0000000000..1746ac240e --- /dev/null +++ b/modules/unimetadata/base-c++-tests @@ -0,0 +1,18 @@ +Files: +tests/unimetadata/test-unimetadata-h-c++.cc + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-unimetadata-h-c++ +check_PROGRAMS += test-unimetadata-h-c++ +test_unimetadata_h_c___SOURCES = unimetadata/test-unimetadata-h-c++.cc +test_unimetadata_h_c___LDADD = $(LDADD) $(LIBUNISTRING) +endif diff --git a/modules/unimetadata/base-tests b/modules/unimetadata/base-tests new file mode 100644 index 0000000000..a783b2e54e --- /dev/null +++ b/modules/unimetadata/base-tests @@ -0,0 +1,13 @@ +Files: +tests/unimetadata/test-unimetadata-h.c + +Depends-on: +unimetadata/base-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-unimetadata-h +check_PROGRAMS += test-unimetadata-h +test_unimetadata_h_SOURCES = unimetadata/test-unimetadata-h.c +test_unimetadata_h_LDADD = $(LDADD) $(LIBUNISTRING) diff --git a/tests/unimetadata/test-unimetadata-h-c++.cc b/tests/unimetadata/test-unimetadata-h-c++.cc new file mode 100644 index 0000000000..ae023b7f2b --- /dev/null +++ b/tests/unimetadata/test-unimetadata-h-c++.cc @@ -0,0 +1,25 @@ +/* Test of <unimetadata.h> in C++ mode. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unimetadata.h> + +int +main () +{ +} diff --git a/tests/unimetadata/test-unimetadata-h.c b/tests/unimetadata/test-unimetadata-h.c new file mode 100644 index 0000000000..9c9bf7eebd --- /dev/null +++ b/tests/unimetadata/test-unimetadata-h.c @@ -0,0 +1,26 @@ +/* Test of <unimetadata.h>. + Copyright (C) 2025 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>. */ + +#include <config.h> + +/* Specification. */ +#include <unimetadata.h> + +int +main (void) +{ + return 0; +} -- 2.51.0
