[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
uc_width and wcwidth optimization
From: |
Alexander V. Lukyanov |
Subject: |
uc_width and wcwidth optimization |
Date: |
Fri, 9 Dec 2011 11:55:48 +0400 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Hello!
Attached is the patch to optimize performance of wcwith, uc_width and
uc{8,16,32}_width functions.
The optimization is caching of is_cjk_encoding() and using
nl_langinfo(CODESET) before the complex locale_charset() to check if the
charset has changed.
Besides, uc_width is used in wcwidth for cjk encodings as designed.
--
Alexander.
diff
Description: Text document
- uc_width and wcwidth optimization,
Alexander V. Lukyanov <=