2024-12-09 Bruno Haible <bruno@clisp.org>
+ xprintf: Use the translation domain "gnulib".
+ * lib/xprintf.c (_): New macro.
+ (xvprintf, xvfprintf): Use it instead of gettext().
+ * modules/xprintf (Depends-on): Add gnulib-i18n.
+
unicodeio: Use the translation domain "gnulib".
* lib/unicodeio.h (unicode_to_mb): Clarify that the message passed to
the failure callback may already be localized.
#include "exitfail.h"
#include "gettext.h"
+#define _(msgid) dgettext ("gnulib", msgid)
+
/* written by Jim Meyering */
/* Just like printf, but call error if it fails without setting the
{
int retval = vprintf (format, args);
if (retval < 0 && ! ferror (stdout))
- error (exit_failure, errno, gettext ("cannot perform formatted output"));
+ error (exit_failure, errno, _("cannot perform formatted output"));
return retval;
}
{
int retval = vfprintf (stream, format, args);
if (retval < 0 && ! ferror (stream))
- error (exit_failure, errno, gettext ("cannot perform formatted output"));
+ error (exit_failure, errno, _("cannot perform formatted output"));
return retval;
}