This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug localedata/14641] Add a strftime()-like function for formatting human names


http://sourceware.org/bugzilla/show_bug.cgi?id=14641

--- Comment #11 from Rich Felker <bugdal at aerifal dot cx> ---
On Thu, Nov 07, 2013 at 12:29:55PM +0000, keld at keldix dot com wrote:
> If there are different users then it is only natural to switch to each user's
> locale, eg when printing a name, or printing an address.

No. Locale names (and whether they even exist) are
implementation-defined. A correct application cannot use locales by
name, but can only use the user's configured locale or the C/POSIX
locale. Applications which assume the existence of particular locale
names are not portable, and even if you only cared about them working
on GNU/Linux systems, many such desktop systems only have one locale
installed (the user's own locale).

Even if you could assume the names and existence of locales, their
definitions may vary slightly between systems, which means the
interpretation of your data would not be portable. The key here is
that name "formatting" is not just presentation, it's actually
interpretation.

> I believe this is in scope of libc, meaning that this is to make an application
> culturally adaptable. It is just a more advanced use than the normal i18n,
> because we want to accomodate different users' cultural conventions.

No, the cultural conventions in question are not cultural conventions
of any users of the system. The data you're working with has been
encoded (I would go so far as to say "corrupted") in a way that's
dependent on the cultural conventions of the person whom it names (or
sometimes not even that, but the cultural conventions imposed on that
person by virtue of where they're living and their legal status
there). The problem is decoding it to the person's actual name.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]