No empty .Rs/.Re
[netbsd-mini2440.git] / gnu / dist / gettext / gettext-tools / src / format-invalid.h
blob8e98a62888e407a85ac0d6481122915557f6e1a2
1 /* Common reasons that make a format string invalid.
2 Copyright (C) 2003 Free Software Foundation, Inc.
3 Written by Bruno Haible <bruno@clisp.org>, 2003.
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2, or (at your option)
8 any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software Foundation,
17 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
19 /* These macros return freshly allocated error message strings, intended
20 to be stored in *invalid_reason. */
22 #define INVALID_UNTERMINATED_DIRECTIVE() \
23 xstrdup (_("The string ends in the middle of a directive."))
25 #define INVALID_MIXES_NUMBERED_UNNUMBERED() \
26 xstrdup (_("The string refers to arguments both through absolute argument numbers and through unnumbered argument specifications."))
28 #define INVALID_ARGNO_0(directive_number) \
29 xasprintf (_("In the directive number %u, the argument number 0 is not a positive integer."), directive_number)
30 #define INVALID_WIDTH_ARGNO_0(directive_number) \
31 xasprintf (_("In the directive number %u, the width's argument number 0 is not a positive integer."), directive_number)
32 #define INVALID_PRECISION_ARGNO_0(directive_number) \
33 xasprintf (_("In the directive number %u, the precision's argument number 0 is not a positive integer."), directive_number)
35 #define INVALID_CONVERSION_SPECIFIER(directive_number,conv_char) \
36 (c_isprint (conv_char) \
37 ? xasprintf (_("In the directive number %u, the character '%c' is not a valid conversion specifier."), directive_number, conv_char) \
38 : xasprintf (_("The character that terminates the directive number %u is not a valid conversion specifier."), directive_number))
40 #define INVALID_INCOMPATIBLE_ARG_TYPES(arg_number) \
41 xasprintf (_("The string refers to argument number %u in incompatible ways."), arg_number)