Artifact 2450591494d7767fca6bec09328a7b5b539176390ef8fd58ebc45eb8fee09d7a:
- File
generators/TableGenerator.h
— part of check-in
[13f2a20288]
at
2010-01-30 18:29:28
on branch trunk
— Change how the Unicode table is stored.
The recent optimization had a bug in the range check and thus did not
notice that an int16_t is not enough to store the difference, thus
leading to broken results. This reverts it to the old way the Unicode
table was stored. (user: js, size: 806) [annotate] [blame] [check-ins using]
/* * Copyright (c) 2008 - 2009 * Jonathan Schleifer <js@webkeks.org> * * All rights reserved. * * This file is part of ObjFW. It may be distributed under the terms of the * Q Public License 1.0, which can be found in the file LICENSE included in * the packaging of this file. */ #import "OFString.h" @interface TableGenerator: OFObject { of_unichar_t upper[0x110000]; of_unichar_t lower[0x110000]; of_unichar_t casefolding[0x110000]; BOOL upper_table_used[0x1100]; BOOL lower_table_used[0x1100]; char casefolding_table_used[0x1100]; size_t upper_size; size_t lower_size; size_t casefolding_size; } - (void)readUnicodeDataFile: (OFString*)path; - (void)readCaseFoldingFile: (OFString*)path; - (void)writeTablesToFile: (OFString*)file; - (void)writeHeaderToFile: (OFString*)file; @end