Author ronaldoussoren
Recipients Dmitry.Jemerov, loewis, ned.deily, r.david.murray, ronaldoussoren, vstinner
Date 2014-03-23.09:04:14
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1395565454.71.0.82462631152.issue18378@psf.upfronthosting.co.za>
In-reply-to
Content
With the following C code:

#include <locale.h>
#include <stdio.h>

int main(void)
{
	char* res = setlocale(LC_CTYPE, "UTF-8");
	printf("Result: %s\n", res);

	res = setlocale(LC_CTYPE, "UTF-9");
	printf("Result: %s\n", res);
	return 0;
}
/* EOF */

I get the following output:

Result: UTF-8
Result: (null)

That is, UTF-8 is a valid locale for LC_CTYPE, and as expected some other string isn't.

BTW. "UTF-8" is only a valid locale for LC_CTYPE, not for other categories (when you change LC_CTYPE to LC_ALL both calls return NULL).
History
Date User Action Args
2014-03-23 09:04:14ronaldoussorensetrecipients: + ronaldoussoren, loewis, vstinner, ned.deily, r.david.murray, Dmitry.Jemerov
2014-03-23 09:04:14ronaldoussorensetmessageid: <1395565454.71.0.82462631152.issue18378@psf.upfronthosting.co.za>
2014-03-23 09:04:14ronaldoussorenlinkissue18378 messages
2014-03-23 09:04:14ronaldoussorencreate