This manual page is for Mac OS X version 10.6.3

If you are running a different version of Mac OS X, view the documentation locally:

  • In Terminal, using the man(1) command

Reading manual pages

Manual pages are intended as a quick reference for people who already understand a technology.

  • For more information about the manual page format, see the manual page for manpages(5).

  • For more information about this technology, look for other documentation in the Apple Reference Library.

  • For general information about writing shell scripts, read Shell Scripting Primer.



NL_LANGINFO(3)                          BSD Library Functions Manual                          NL_LANGINFO(3)

NAME
     nl_langinfo, nl_langinfo_l -- language information

LIBRARY
     Standard C Library (libc, -lc)

SYNOPSIS
     #include <langinfo.h>

     char *
     nl_langinfo(nl_item item);

     #include <langinfo.h>
     #include <xlocale.h>

     char *
     nl_langinfo_l(nl_item item, locale_t loc);

DESCRIPTION
     The nl_langinfo() function returns a pointer to a string containing information relevant to the partic-ular particular
     ular language or cultural area defined in the program's locale.  The manifest constant names and values
     of item are defined in <langinfo.h>.

     Calls to setlocale() with a category corresponding to the category of item, or to the category LC_ALL,
     may overwrite the buffer pointed to by the return value.

EXAMPLES
     For example:

           nl_langinfo(ABDAY_1)

     would return a pointer to the string "Dom" if the identified language was Portuguese, and "Sun" if the
     identified language was English.

     While the nl_langinfo() function uses the current locale, the nl_langinfo_l() function may be passed a
     locale directly. See xlocale(3) for more information.

RETURN VALUES
     In a locale where langinfo data is not defined, nl_langinfo() returns a pointer to the corresponding
     string in the POSIX locale.  In all locales, nl_langinfo() returns a pointer to an empty string if item
     contains an invalid setting.

SEE ALSO
     setlocale(3), xlocale(3)

STANDARDS
     The nl_langinfo() function conforms to Version 2 of the Single UNIX Specification (``SUSv2'').

HISTORY
     The nl_langinfo() function first appeared in FreeBSD 4.6.

BSD                                              May 3, 2001                                             BSD

Reporting Problems

The way to report a problem with this manual page depends on the type of problem:

Content errors
Report errors in the content of this documentation with the feedback links below.
Bug reports
Report bugs in the functionality of the described tool or API through Bug Reporter.
Formatting problems
Report formatting mistakes in the online version of these pages with the feedback links below.

Did this document help you? Yes It's good, but... Not helpful...