Question about ASCII and nl_langinfo (locale work)

Ed Schouten ed at nuxi.nl
Mon Nov 16 17:35:04 UTC 2015


Hi Baptiste,

I personally think it's a shame if we were to deviate from returning
"US-ASCII", for the reason that "US-ASCII" also happens to be the
preferred MIME name for the character set:

http://www.iana.org/assignments/character-sets/character-sets.xhtml

"ASCII" doesn't even seem to be an alias for this character set.
Though "ANSI_X3.4-1968" is an alias for ASCII, I wouldn't even know
that this is ASCII without doing a Google search.

In my opinion a decent implementation of newlocale() should support
any of the character set names and aliases provided on the IANA page,
but let nl_langinfo(CODESET) return the preferred MIME name.

> That means we need to teach all upstream about US-ASCII all the time.

Could you come up with a concrete list of pieces of software that need
to be changed? Is it just those three pieces of software that you
mentioned above? If so, then I think it would be a shame to make the
concession.

-- 
Ed Schouten <ed at nuxi.nl>
Nuxi, 's-Hertogenbosch, the Netherlands
KvK-nr.: 62051717


More information about the freebsd-arch mailing list