GCC Middle and Back End API Reference
intl.h File Reference

Go to the source code of this file.

Macros

#define setlocale(category, locale)
#define textdomain(domain)
#define bindtextdomain(domain, directory)
#define gettext(msgid)
#define ngettext(singular, plural, n)
#define gcc_init_libintl()
#define gcc_gettext_width(s)
#define _(msgid)
#define N_(msgid)
#define G_(gmsgid)

Functions

const char * fake_ngettext (const char *singular, const char *plural, unsigned long int n)
char * get_spaces (const char *)

Variables

const char * open_quote
const char * close_quote
const char * locale_encoding
bool locale_utf8

Macro Definition Documentation

◆ _

◆ bindtextdomain

#define bindtextdomain ( domain,
directory )
Value:
(domain)

◆ G_

◆ gcc_gettext_width

#define gcc_gettext_width ( s)
Value:
strlen (s)

Referenced by get_spaces().

◆ gcc_init_libintl

#define gcc_init_libintl ( )
Value:
/* nothing @endverbatim */

Referenced by general_init(), driver::global_initializations(), main(), main(), and main().

◆ gettext

#define gettext ( msgid)
Value:
(msgid)

◆ N_

#define N_ ( msgid)
Value:
msgid
Used to mark strings that will be translated later.

Referenced by print_version(), read_count_file(), and diagnostic_text_output_format::report_current_module().

◆ ngettext

#define ngettext ( singular,
plural,
n )
Value:
fake_ngettext (singular, plural, n)
const char * fake_ngettext(const char *singular, const char *plural, unsigned long n)
Definition intl.cc:125

Referenced by diagnostic_context::diagnostic_n_impl(), format_string_diagnostic_t::emit_warning_n_va(), main(), and pp_printf_n().

◆ setlocale

#define setlocale ( category,
locale )
Value:
(locale)
intl.h - internationalization Copyright (C) 1998-2025 Free Software Foundation, Inc. GCC 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, or (at your option) any later version. GCC 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 GCC; see the file COPYING3. If not see <http://www.gnu.org/licenses/>.

◆ textdomain

#define textdomain ( domain)
Value:
(domain)
Stubs.

Function Documentation

◆ fake_ngettext()

const char * fake_ngettext ( const char * singular,
const char * plural,
unsigned long int n )
extern

◆ get_spaces()

char * get_spaces ( const char * str)
extern
Return the indent for successive lines, using the width of the STR. STR must have been translated already. The string must be freed by the caller.

References gcc_gettext_width.

Variable Documentation

◆ close_quote

const char* close_quote
extern
Closing quotation mark for diagnostics.

Referenced by pp_end_quote(), and html_token_printer::print_tokens().

◆ locale_encoding

const char* locale_encoding
extern
The name of the locale encoding.

Referenced by identifier_to_locale().

◆ locale_utf8

bool locale_utf8
extern
Whether the locale is using UTF-8.

Referenced by identifier_to_locale().

◆ open_quote

const char* open_quote
extern
Message translation utilities. Copyright (C) 2001-2025 Free Software Foundation, Inc. This file is part of GCC. GCC 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, or (at your option) any later version. GCC 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 GCC; see the file COPYING3. If not see <http://www.gnu.org/licenses/>.
Opening quotation mark for diagnostics.

Referenced by pp_begin_quote(), and html_token_printer::print_tokens().