summaryrefslogtreecommitdiff
path: root/modules/uniwidth/width
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2021-12-31 23:53:39 +0100
committerBruno Haible <bruno@clisp.org>2021-12-31 23:53:39 +0100
commitf698ea718e839e373702664e54cf240fe3682f34 (patch)
tree12db511c4663a69e7f3c098f3d27236c46905add /modules/uniwidth/width
parent14db2b71b5bd05b94ec6126617fd32cd5f1016cd (diff)
downloadgnulib-f698ea718e839e373702664e54cf240fe3682f34.tar.gz
uniwidth: Optimize.
* lib/gen-uni-tables.c (output_nonspacing_property): Add version parameter. Emit the usual boilerplate header for generated files. (is_width2): New function, based on lib/uniwidth/width.c. (output_width2_property): New function. (main): Create uniwidth/width0.h instead of uniwidth/width.c.part. Create uniwidth/width2.h. * lib/uniwidth/width.c: Include width0.h, width2.h, bitmap.h. (nonspacing_table_data, nonspacing_table_ind): Remove here. (uc_width): Replace the double-width character with an u_width2 bitmap lookup. * modules/uniwidth/width (Files): Add lib/uniwidth/width0.h, lib/uniwidth/width2.h, lib/unictype/bitmap.h.
Diffstat (limited to 'modules/uniwidth/width')
-rw-r--r--modules/uniwidth/width3
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/uniwidth/width b/modules/uniwidth/width
index 3c0c9675b2..e1701abeef 100644
--- a/modules/uniwidth/width
+++ b/modules/uniwidth/width
@@ -4,6 +4,9 @@ Determine display width of Unicode character.
Files:
lib/uniwidth/width.c
lib/uniwidth/cjk.h
+lib/uniwidth/width0.h
+lib/uniwidth/width2.h
+lib/unictype/bitmap.h
Depends-on:
uniwidth/base