From: Bruno Haible Date: Fri, 27 Dec 2024 22:29:02 +0000 (+0100) Subject: Rename module stdnoreturn to stdnoreturn-h. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4da657e525eba91dc0206f1204af9bfe501315dc;p=thirdparty%2Fgnulib.git Rename module stdnoreturn to stdnoreturn-h. * modules/stdnoreturn-h: Renamed from modules/stdnoreturn. * modules/stdnoreturn-h-tests: Renamed from modules/stdnoreturn-tests. * tests/test-stdnoreturn-h.c: Renamed from tests/test-stdnoreturn.c. * doc/posix-headers/stdnoreturn.texi: Update. * doc/noreturn.texi: Update. * modules/stdnoreturn: New file. --- diff --git a/ChangeLog b/ChangeLog index 5b3de5831c..adf50e86c7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2024-12-27 Bruno Haible + + Rename module stdnoreturn to stdnoreturn-h. + * modules/stdnoreturn-h: Renamed from modules/stdnoreturn. + * modules/stdnoreturn-h-tests: Renamed from modules/stdnoreturn-tests. + * tests/test-stdnoreturn-h.c: Renamed from tests/test-stdnoreturn.c. + * doc/posix-headers/stdnoreturn.texi: Update. + * doc/noreturn.texi: Update. + * modules/stdnoreturn: New file. + 2024-12-27 Bruno Haible Rename module stdlib to stdlib-h. diff --git a/doc/noreturn.texi b/doc/noreturn.texi index 2356eda111..06bc791621 100644 --- a/doc/noreturn.texi +++ b/doc/noreturn.texi @@ -12,8 +12,8 @@ @section Non-returning Functions @cindex @code{_Noreturn} -@cindex @code{noreturn} -@cindex @code{stdnoreturn} +@mindex @code{noreturn} +@mindex @code{stdnoreturn-h} A "non-returning" function is a function which cannot return normally. Instead of returning, it can loop forever, or it can transfer control via @code{abort}, @code{execvp}, @code{exit}, @code{longjmp}, @code{throw} @@ -57,6 +57,6 @@ you should use @code{_Noreturn}; otherwise the module @code{noreturn} provides for better data-flow analysis and thus for better warnings. -@mindex stdnoreturn -There is also an obsolete @code{stdnoreturn} module, but its use is no +@mindex stdnoreturn-h +There is also an obsolete @code{stdnoreturn-h} module, but its use is no longer recommended. diff --git a/doc/posix-headers/stdnoreturn.texi b/doc/posix-headers/stdnoreturn.texi index de1cce7be0..03564a574d 100644 --- a/doc/posix-headers/stdnoreturn.texi +++ b/doc/posix-headers/stdnoreturn.texi @@ -5,8 +5,8 @@ ISO C23 specification:@* @url{https://www.open-std.org/jtc1/sc22/wg14/www/docs/n POSIX specification:@* @url{https://pubs.opengroup.org/onlinepubs/9799919799/basedefs/stdnoreturn.h.html} -Gnulib module: stdnoreturn -@mindex stdnoreturn +Gnulib module: stdnoreturn-h +@mindex stdnoreturn-h Portability problems fixed by Gnulib: @itemize diff --git a/modules/stdnoreturn b/modules/stdnoreturn index e283fd18fb..086917e963 100644 --- a/modules/stdnoreturn +++ b/modules/stdnoreturn @@ -1,40 +1,20 @@ Description: A that nearly conforms to ISO C11. +Status: +deprecated + Notice: -The module 'stdnoreturn' is deprecated. -New code should use the '_Noreturn' keyword or the 'noreturn' module. +This module is deprecated. Use the module 'stdnoreturn-h' instead. Files: -lib/stdnoreturn.in.h -m4/stdnoreturn.m4 Depends-on: -gen-header -snippet/_Noreturn +stdnoreturn-h configure.ac: -gl_STDNORETURN_H -gl_CONDITIONAL_HEADER([stdnoreturn.h]) -AC_PROG_MKDIR_P Makefile.am: -BUILT_SOURCES += $(STDNORETURN_H) - -# We need the following in order to create when the system -# doesn't have one that works. -if GL_GENERATE_STDNORETURN_H -stdnoreturn.h: stdnoreturn.in.h $(top_builddir)/config.status $(_NORETURN_H) -@NMD@ $(AM_V_GEN)$(MKDIR_P) '%reldir%' - $(gl_V_at)$(SED_HEADER_STDOUT) \ - -e '/definition of _Noreturn/r $(_NORETURN_H)' \ - $(srcdir)/stdnoreturn.in.h > $@-t - $(AM_V_at)mv $@-t $@ -else -stdnoreturn.h: $(top_builddir)/config.status - rm -f $@ -endif -MOSTLYCLEANFILES += stdnoreturn.h stdnoreturn.h-t Include: @@ -43,4 +23,3 @@ License: LGPLv2+ Maintainer: -Paul Eggert diff --git a/modules/stdnoreturn-h b/modules/stdnoreturn-h new file mode 100644 index 0000000000..e283fd18fb --- /dev/null +++ b/modules/stdnoreturn-h @@ -0,0 +1,46 @@ +Description: +A that nearly conforms to ISO C11. + +Notice: +The module 'stdnoreturn' is deprecated. +New code should use the '_Noreturn' keyword or the 'noreturn' module. + +Files: +lib/stdnoreturn.in.h +m4/stdnoreturn.m4 + +Depends-on: +gen-header +snippet/_Noreturn + +configure.ac: +gl_STDNORETURN_H +gl_CONDITIONAL_HEADER([stdnoreturn.h]) +AC_PROG_MKDIR_P + +Makefile.am: +BUILT_SOURCES += $(STDNORETURN_H) + +# We need the following in order to create when the system +# doesn't have one that works. +if GL_GENERATE_STDNORETURN_H +stdnoreturn.h: stdnoreturn.in.h $(top_builddir)/config.status $(_NORETURN_H) +@NMD@ $(AM_V_GEN)$(MKDIR_P) '%reldir%' + $(gl_V_at)$(SED_HEADER_STDOUT) \ + -e '/definition of _Noreturn/r $(_NORETURN_H)' \ + $(srcdir)/stdnoreturn.in.h > $@-t + $(AM_V_at)mv $@-t $@ +else +stdnoreturn.h: $(top_builddir)/config.status + rm -f $@ +endif +MOSTLYCLEANFILES += stdnoreturn.h stdnoreturn.h-t + +Include: + + +License: +LGPLv2+ + +Maintainer: +Paul Eggert diff --git a/modules/stdnoreturn-h-tests b/modules/stdnoreturn-h-tests new file mode 100644 index 0000000000..ec5b72cf88 --- /dev/null +++ b/modules/stdnoreturn-h-tests @@ -0,0 +1,10 @@ +Files: +tests/test-stdnoreturn-h.c + +Depends-on: + +configure.ac: + +Makefile.am: +TESTS += test-stdnoreturn-h +check_PROGRAMS += test-stdnoreturn-h diff --git a/modules/stdnoreturn-tests b/modules/stdnoreturn-tests deleted file mode 100644 index 1d1f820039..0000000000 --- a/modules/stdnoreturn-tests +++ /dev/null @@ -1,10 +0,0 @@ -Files: -tests/test-stdnoreturn.c - -Depends-on: - -configure.ac: - -Makefile.am: -TESTS += test-stdnoreturn -check_PROGRAMS += test-stdnoreturn diff --git a/tests/test-stdnoreturn.c b/tests/test-stdnoreturn-h.c similarity index 100% rename from tests/test-stdnoreturn.c rename to tests/test-stdnoreturn-h.c