pcre_chartables.c

Go to the documentation of this file.
00001 /*************************************************
00002 *      Perl-Compatible Regular Expressions       *
00003 *************************************************/
00004 
00005 /* This file contains character tables that are used when no external tables
00006 are passed to PCRE by the application that calls it. The tables are used only
00007 for characters whose code values are less than 256.
00008 
00009 This is a default version of the tables that assumes ASCII encoding. A program
00010 called dftables (which is distributed with PCRE) can be used to build
00011 alternative versions of this file. This is necessary if you are running in an
00012 EBCDIC environment, or if you want to default to a different encoding, for
00013 example ISO-8859-1. When dftables is run, it creates these tables in the
00014 current locale. If PCRE is configured with --enable-rebuild-chartables, this
00015 happens automatically.
00016 
00017 The following #includes are present because without the gcc 4.x may remove the
00018 array definition from the final binary if PCRE is built into a static library
00019 and dead code stripping is activated. This leads to link errors. Pulling in the
00020 header ensures that the array gets flagged as "someone outside this compilation
00021 unit might reference this" and so it will always be supplied to the linker. */
00022 
00023 #ifdef HAVE_CONFIG_H
00024 #include "config.h"
00025 #endif
00026 
00027 #include "pcre_internal.h"
00028 
00029 const unsigned char _pcre_default_tables[] = {
00030 
00031 /* This table is a lower casing table. */
00032 
00033     0,  1,  2,  3,  4,  5,  6,  7,
00034     8,  9, 10, 11, 12, 13, 14, 15,
00035    16, 17, 18, 19, 20, 21, 22, 23,
00036    24, 25, 26, 27, 28, 29, 30, 31,
00037    32, 33, 34, 35, 36, 37, 38, 39,
00038    40, 41, 42, 43, 44, 45, 46, 47,
00039    48, 49, 50, 51, 52, 53, 54, 55,
00040    56, 57, 58, 59, 60, 61, 62, 63,
00041    64, 97, 98, 99,100,101,102,103,
00042   104,105,106,107,108,109,110,111,
00043   112,113,114,115,116,117,118,119,
00044   120,121,122, 91, 92, 93, 94, 95,
00045    96, 97, 98, 99,100,101,102,103,
00046   104,105,106,107,108,109,110,111,
00047   112,113,114,115,116,117,118,119,
00048   120,121,122,123,124,125,126,127,
00049   128,129,130,131,132,133,134,135,
00050   136,137,138,139,140,141,142,143,
00051   144,145,146,147,148,149,150,151,
00052   152,153,154,155,156,157,158,159,
00053   160,161,162,163,164,165,166,167,
00054   168,169,170,171,172,173,174,175,
00055   176,177,178,179,180,181,182,183,
00056   184,185,186,187,188,189,190,191,
00057   192,193,194,195,196,197,198,199,
00058   200,201,202,203,204,205,206,207,
00059   208,209,210,211,212,213,214,215,
00060   216,217,218,219,220,221,222,223,
00061   224,225,226,227,228,229,230,231,
00062   232,233,234,235,236,237,238,239,
00063   240,241,242,243,244,245,246,247,
00064   248,249,250,251,252,253,254,255,
00065 
00066 /* This table is a case flipping table. */
00067 
00068     0,  1,  2,  3,  4,  5,  6,  7,
00069     8,  9, 10, 11, 12, 13, 14, 15,
00070    16, 17, 18, 19, 20, 21, 22, 23,
00071    24, 25, 26, 27, 28, 29, 30, 31,
00072    32, 33, 34, 35, 36, 37, 38, 39,
00073    40, 41, 42, 43, 44, 45, 46, 47,
00074    48, 49, 50, 51, 52, 53, 54, 55,
00075    56, 57, 58, 59, 60, 61, 62, 63,
00076    64, 97, 98, 99,100,101,102,103,
00077   104,105,106,107,108,109,110,111,
00078   112,113,114,115,116,117,118,119,
00079   120,121,122, 91, 92, 93, 94, 95,
00080    96, 65, 66, 67, 68, 69, 70, 71,
00081    72, 73, 74, 75, 76, 77, 78, 79,
00082    80, 81, 82, 83, 84, 85, 86, 87,
00083    88, 89, 90,123,124,125,126,127,
00084   128,129,130,131,132,133,134,135,
00085   136,137,138,139,140,141,142,143,
00086   144,145,146,147,148,149,150,151,
00087   152,153,154,155,156,157,158,159,
00088   160,161,162,163,164,165,166,167,
00089   168,169,170,171,172,173,174,175,
00090   176,177,178,179,180,181,182,183,
00091   184,185,186,187,188,189,190,191,
00092   192,193,194,195,196,197,198,199,
00093   200,201,202,203,204,205,206,207,
00094   208,209,210,211,212,213,214,215,
00095   216,217,218,219,220,221,222,223,
00096   224,225,226,227,228,229,230,231,
00097   232,233,234,235,236,237,238,239,
00098   240,241,242,243,244,245,246,247,
00099   248,249,250,251,252,253,254,255,
00100 
00101 /* This table contains bit maps for various character classes. Each map is 32
00102 bytes long and the bits run from the least significant end of each byte. The
00103 classes that have their own maps are: space, xdigit, digit, upper, lower, word,
00104 graph, print, punct, and cntrl. Other classes are built from combinations. */
00105 
00106   0x00,0x3e,0x00,0x00,0x01,0x00,0x00,0x00,
00107   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00108   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00109   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00110 
00111   0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x03,
00112   0x7e,0x00,0x00,0x00,0x7e,0x00,0x00,0x00,
00113   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00114   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00115 
00116   0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x03,
00117   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00118   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00119   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00120 
00121   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00122   0xfe,0xff,0xff,0x07,0x00,0x00,0x00,0x00,
00123   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00124   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00125 
00126   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00127   0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x07,
00128   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00129   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00130 
00131   0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x03,
00132   0xfe,0xff,0xff,0x87,0xfe,0xff,0xff,0x07,
00133   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00134   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00135 
00136   0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,
00137   0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f,
00138   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00139   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00140 
00141   0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff,
00142   0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f,
00143   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00144   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00145 
00146   0x00,0x00,0x00,0x00,0xfe,0xff,0x00,0xfc,
00147   0x01,0x00,0x00,0xf8,0x01,0x00,0x00,0x78,
00148   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00149   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00150 
00151   0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,
00152   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,
00153   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00154   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
00155 
00156 /* This table identifies various classes of character by individual bits:
00157   0x01   white space character
00158   0x02   letter
00159   0x04   decimal digit
00160   0x08   hexadecimal digit
00161   0x10   alphanumeric or '_'
00162   0x80   regular expression metacharacter or binary zero
00163 */
00164 
00165   0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /*   0-  7 */
00166   0x00,0x01,0x01,0x00,0x01,0x01,0x00,0x00, /*   8- 15 */
00167   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /*  16- 23 */
00168   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /*  24- 31 */
00169   0x01,0x00,0x00,0x00,0x80,0x00,0x00,0x00, /*    - '  */
00170   0x80,0x80,0x80,0x80,0x00,0x00,0x80,0x00, /*  ( - /  */
00171   0x1c,0x1c,0x1c,0x1c,0x1c,0x1c,0x1c,0x1c, /*  0 - 7  */
00172   0x1c,0x1c,0x00,0x00,0x00,0x00,0x00,0x80, /*  8 - ?  */
00173   0x00,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x12, /*  @ - G  */
00174   0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, /*  H - O  */
00175   0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, /*  P - W  */
00176   0x12,0x12,0x12,0x80,0x80,0x00,0x80,0x10, /*  X - _  */
00177   0x00,0x1a,0x1a,0x1a,0x1a,0x1a,0x1a,0x12, /*  ` - g  */
00178   0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, /*  h - o  */
00179   0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, /*  p - w  */
00180   0x12,0x12,0x12,0x80,0x80,0x00,0x00,0x00, /*  x -127 */
00181   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 128-135 */
00182   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 136-143 */
00183   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 144-151 */
00184   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 152-159 */
00185   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 160-167 */
00186   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 168-175 */
00187   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 176-183 */
00188   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 184-191 */
00189   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 192-199 */
00190   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 200-207 */
00191   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 208-215 */
00192   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 216-223 */
00193   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 224-231 */
00194   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 232-239 */
00195   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 240-247 */
00196   0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};/* 248-255 */
00197 
00198 /* End of pcre_chartables.c */

Generated on Tue Jul 5 14:11:58 2011 for ROOT_528-00b_version by  doxygen 1.5.1