From 6b6a5ffe15fc27f43636ff3ad2efee32b77b0cff Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sun, 16 Feb 2025 11:34:23 +0100 Subject: [PATCH] ctype-h: Make ctype.h self-contained again (regr. 2025-02-14). * lib/ctype.in.h: Add comments re _GL_ARG_NONNULL. * modules/ctype-h (Depends-on): Add snippet/arg-nonnull. (Makefile.am): Substitute $(ARG_NONNULL_H) into ctype.h. --- ChangeLog | 7 +++++++ lib/ctype.in.h | 4 +++- modules/ctype-h | 4 +++- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index c949a1385d..53bb437073 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2025-02-16 Bruno Haible + + ctype-h: Make ctype.h self-contained again (regr. 2025-02-14). + * lib/ctype.in.h: Add comments re _GL_ARG_NONNULL. + * modules/ctype-h (Depends-on): Add snippet/arg-nonnull. + (Makefile.am): Substitute $(ARG_NONNULL_H) into ctype.h. + 2025-02-16 Bruno Haible bootstrap: Fix recognition of --depth option with recent git releases. diff --git a/lib/ctype.in.h b/lib/ctype.in.h index 130ef7e0d3..f0e62395b3 100644 --- a/lib/ctype.in.h +++ b/lib/ctype.in.h @@ -49,7 +49,7 @@ #ifndef _@GUARD_PREFIX@_CTYPE_H #define _@GUARD_PREFIX@_CTYPE_H -/* This file uses GNULIB_POSIXCHECK, HAVE_RAW_DECL_*. */ +/* This file uses _GL_ARG_NONNULL, GNULIB_POSIXCHECK, HAVE_RAW_DECL_*. */ #if !_GL_CONFIG_H_INCLUDED #error "Please include config.h first." #endif @@ -65,6 +65,8 @@ /* The definitions of _GL_FUNCDECL_RPL etc. are copied here. */ +/* The definition of _GL_ARG_NONNULL is copied here. */ + /* The definition of _GL_WARN_ON_USE is copied here. */ /* Return non-zero if c is alphanumeric. */ diff --git a/modules/ctype-h b/modules/ctype-h index 56edc715b6..3caaad5f5c 100644 --- a/modules/ctype-h +++ b/modules/ctype-h @@ -9,6 +9,7 @@ Depends-on: extern-inline gen-header include_next +snippet/arg-nonnull snippet/c++defs snippet/warn-on-use @@ -22,7 +23,7 @@ BUILT_SOURCES += ctype.h # We need the following in order to create when the system # doesn't have one that works with the given compiler. -ctype.h: ctype.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(WARN_ON_USE_H) +ctype.h: ctype.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H) $(WARN_ON_USE_H) @NMD@ $(AM_V_GEN)$(MKDIR_P) '%reldir%' $(gl_V_at)$(SED_HEADER_STDOUT) \ -e 's|@''GUARD_PREFIX''@|${gl_include_guard_prefix}|g' \ @@ -61,6 +62,7 @@ ctype.h: ctype.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(WARN_ON_USE_H) -e 's/@''HAVE_TOLOWER_L''@/$(HAVE_TOLOWER_L)/g' \ -e 's/@''HAVE_TOUPPER_L''@/$(HAVE_TOUPPER_L)/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ -e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \ $(srcdir)/ctype.in.h > $@-t $(AM_V_at)mv $@-t $@ -- 2.39.5