[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

strcoll, C, ru_RU.KOI8-R

Could you please tell me the group where I could ask about strcoll,
and it's behaviour in different locales?

If it's too a specific question for debian-user, please ignore the rest...

The following prog.
main(int argc, char * argv [])
   if (argc > 1)
   setlocale(LC_COLLATE, "ru_RU.KOI8-R");
   setlocale(LC_COLLATE, "C");
   printf("%d\n", strcoll("a-name", "aname"));
prints -65 if called w/o args, and 1 if with them. I found it hell hard to understand. Any clue which might help me in resolving this mistery would be appreciated. In both locales minus-dash is sure preceding any letter, e.g., strcoll returns <0 if called with "-"
as first arg, and any letter as the second.

Vladimir Zolotykh

Reply to: