TheGNUGeneralPublicLicenseisoftenshippedwithGNUsoftware,and isgenerallykeptinafilecalledCOPYINGorLICENSE.Ifyoudonot haveacopyofthelicense,writetotheFreeSoftwareFoundation,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA. */ #define READLINE_LIBRARY
#ifdefined (HAVE_CONFIG_H) # include "config_readline.h" #endif
#include <sys/types.h>
#include <stdio.h>
#ifdefined (HAVE_UNISTD_H) # include <unistd.h> #endif/* HAVE_UNISTD_H */
#ifdefined (HAVE_STDLIB_H) # include <stdlib.h> #else # include "ansi_stdlib.h" #endif/* HAVE_STDLIB_H */
#ifdefined (HAVE_LOCALE_H) # include <locale.h> #endif
/* Check for LC_ALL, LC_CTYPE, and LANG and use the first with a value todecidethedefaultsfor8-bitcharacterinputandoutput.Returns
1 if we set eight-bit mode. */ int
_rl_init_eightbit ()
{ /* If we have setlocale(3), just check the current LC_CTYPE category
value, and go into eight-bit mode if it's not C or POSIX. */ #ifdefined (HAVE_SETLOCALE) constchar *lspec; char *t;
/* Set the LC_CTYPE locale category from environment variables. */
lspec = _rl_get_locale_var ("LC_CTYPE"); /* Since _rl_get_locale_var queries the right environment variables, wequerythecurrentlocalesettingswithsetlocale(),and,if thatdoesn'treturnanything,wesetlspectotheemptystringto forcethesubsequentcalltosetlocale()todefinethe`native'
environment. */ if (lspec == 0 || *lspec == 0)
lspec = setlocale (LC_CTYPE, (char *)NULL); if (lspec == 0)
lspec = "";
t = setlocale (LC_CTYPE, lspec);
#else/* !HAVE_SETLOCALE */ constchar *lspec; char *t; int i;
/* We don't have setlocale. Finesse it. Check the environment for the appropriatevariablesandseteight-bitmodeiftheyhavetheright
values. */
lspec = _rl_get_locale_var ("LC_CTYPE");
if (lspec == 0 || (t = normalize_codeset (lspec)) == 0) return (0); for (i = 0; t && legal_lang_values[i]; i++) if (STREQ (t, legal_lang_values[i]))
{
_rl_meta_flag = 1;
_rl_convert_meta_chars_to_ascii = 0;
_rl_output_meta_chars = 1; break;
}
free (t); return (legal_lang_values[i] ? 1 : 0);
/* This does not make sense: language has to be specified. As anexceptionweallowthevariabletocontainonlythecodeset
name. Perhaps there are funny codeset names. */ if (language == cp)
{
*lenp = strlen (language);
result = language;
} else
{ /* Next is the territory. */ if (*cp == '_') do
++cp; while (*cp && *cp != '.' && *cp != '@' && *cp != '+' && *cp != ',' && *cp != '_');
/* Now, finally, is the codeset. */
result = cp; if (*cp == '.') do
++cp; while (*cp && *cp != '@');
if (cp - result > 2)
{
result++;
*lenp = cp - result;
} else
{
*lenp = strlen (language);
result = language;
}
}
return result;
} #endif/* !HAVE_SETLOCALE */
Messung V0.5 in Prozent
¤ Dauer der Verarbeitung: 0.8 Sekunden
(vorverarbeitet am 2026-10-08)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.