diff options
author | Fredrik Lundh <fredrik@pythonware.com> | 2000-09-24 21:45:34 (GMT) |
---|---|---|
committer | Fredrik Lundh <fredrik@pythonware.com> | 2000-09-24 21:45:34 (GMT) |
commit | a4287c29b343dec5115672fd1ff1325f322dec1b (patch) | |
tree | 167f42fcadee9ea141e202e6cf1d6a29c2a1ef9a | |
parent | 58af43fd760c2d7d0d8238b7919cf8fa9f1b6dbe (diff) | |
download | cpython-a4287c29b343dec5115672fd1ff1325f322dec1b.zip cpython-a4287c29b343dec5115672fd1ff1325f322dec1b.tar.gz cpython-a4287c29b343dec5115672fd1ff1325f322dec1b.tar.bz2 |
unicode database compression, step 1:
- use unidb compression for the unicodedata module. on Windows,
the new unidatabase module is 120k, down from nearly 600k.
-rw-r--r-- | Modules/unicodedata.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/Modules/unicodedata.c b/Modules/unicodedata.c index 36c6566..e15ff27 100644 --- a/Modules/unicodedata.c +++ b/Modules/unicodedata.c @@ -13,17 +13,7 @@ Copyright (c) Corporation for National Research Initiatives. #include "Python.h" #include "unicodedatabase.h" -/* --- Helpers ------------------------------------------------------------ */ - -static -const _PyUnicode_DatabaseRecord *unicode_db(register int i) -{ - register int page = i >> 12; - - if (page < sizeof(_PyUnicode_Database)) - return &_PyUnicode_Database[page][i & 0x0fff]; - return &_PyUnicode_Database[0][0]; -} +#define unicode_db _PyUnicode_Database_GetRecord /* --- Module API --------------------------------------------------------- */ |