OLD | NEW |
1 /* | 1 /* |
2 ******************************************************************************* | 2 ******************************************************************************* |
3 * | 3 * |
4 * Copyright (C) 1999-2013, International Business Machines | 4 * Copyright (C) 1999-2014, International Business Machines |
5 * Corporation and others. All Rights Reserved. | 5 * Corporation and others. All Rights Reserved. |
6 * | 6 * |
7 ******************************************************************************* | 7 ******************************************************************************* |
8 * file name: uniset_props.cpp | 8 * file name: uniset_props.cpp |
9 * encoding: US-ASCII | 9 * encoding: US-ASCII |
10 * tab size: 8 (not used) | 10 * tab size: 8 (not used) |
11 * indentation:4 | 11 * indentation:4 |
12 * | 12 * |
13 * created on: 2004aug25 | 13 * created on: 2004aug25 |
14 * created by: Markus W. Scherer | 14 * created by: Markus W. Scherer |
(...skipping 25 matching lines...) Expand all Loading... |
40 #include "uprops.h" | 40 #include "uprops.h" |
41 #include "charstr.h" | 41 #include "charstr.h" |
42 #include "cstring.h" | 42 #include "cstring.h" |
43 #include "mutex.h" | 43 #include "mutex.h" |
44 #include "umutex.h" | 44 #include "umutex.h" |
45 #include "uassert.h" | 45 #include "uassert.h" |
46 #include "hash.h" | 46 #include "hash.h" |
47 | 47 |
48 U_NAMESPACE_USE | 48 U_NAMESPACE_USE |
49 | 49 |
50 #define LENGTHOF(array) (int32_t)(sizeof(array)/sizeof((array)[0])) | |
51 | |
52 // initial storage. Must be >= 0 | 50 // initial storage. Must be >= 0 |
53 // *** same as in uniset.cpp ! *** | 51 // *** same as in uniset.cpp ! *** |
54 #define START_EXTRA 16 | 52 #define START_EXTRA 16 |
55 | 53 |
56 // Define UChar constants using hex for EBCDIC compatibility | 54 // Define UChar constants using hex for EBCDIC compatibility |
57 // Used #define to reduce private static exports and memory access time. | 55 // Used #define to reduce private static exports and memory access time. |
58 #define SET_OPEN ((UChar)0x005B) /*[*/ | 56 #define SET_OPEN ((UChar)0x005B) /*[*/ |
59 #define SET_CLOSE ((UChar)0x005D) /*]*/ | 57 #define SET_CLOSE ((UChar)0x005D) /*]*/ |
60 #define HYPHEN ((UChar)0x002D) /*-*/ | 58 #define HYPHEN ((UChar)0x002D) /*-*/ |
61 #define COMPLEMENT ((UChar)0x005E) /*^*/ | 59 #define COMPLEMENT ((UChar)0x005E) /*^*/ |
(...skipping 1231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1293 if (pos.getIndex() == 0) { | 1291 if (pos.getIndex() == 0) { |
1294 // syntaxError(chars, "Invalid property pattern"); | 1292 // syntaxError(chars, "Invalid property pattern"); |
1295 ec = U_MALFORMED_SET; | 1293 ec = U_MALFORMED_SET; |
1296 return; | 1294 return; |
1297 } | 1295 } |
1298 chars.jumpahead(pos.getIndex()); | 1296 chars.jumpahead(pos.getIndex()); |
1299 rebuiltPat.append(pattern, 0, pos.getIndex()); | 1297 rebuiltPat.append(pattern, 0, pos.getIndex()); |
1300 } | 1298 } |
1301 | 1299 |
1302 U_NAMESPACE_END | 1300 U_NAMESPACE_END |
OLD | NEW |