/[pcre]/code/trunk/pcre_internal.h
ViewVC logotype

Diff of /code/trunk/pcre_internal.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 348 by ph10, Mon Apr 28 15:10:02 2008 UTC revision 349 by ph10, Wed Jul 2 18:42:11 2008 UTC
# Line 140  preprocessor time in standard C environm Line 140  preprocessor time in standard C environm
140    
141  #if USHRT_MAX == 65535  #if USHRT_MAX == 65535
142    typedef unsigned short pcre_uint16;    typedef unsigned short pcre_uint16;
143      typedef short pcre_int16;
144  #elif UINT_MAX == 65535  #elif UINT_MAX == 65535
145    typedef unsigned int pcre_uint16;    typedef unsigned int pcre_uint16;
146      typedef int pcre_int16;
147  #else  #else
148    #error Cannot determine a type for 16-bit unsigned integers    #error Cannot determine a type for 16-bit unsigned integers
149  #endif  #endif
150    
151  #if UINT_MAX == 4294967295  #if UINT_MAX == 4294967295
152    typedef unsigned int pcre_uint32;    typedef unsigned int pcre_uint32;
153      typedef int pcre_int32;
154  #elif ULONG_MAX == 4294967295  #elif ULONG_MAX == 4294967295
155    typedef unsigned long int pcre_uint32;    typedef unsigned long int pcre_uint32;
156      typedef long int pcre_int32;
157  #else  #else
158    #error Cannot determine a type for 32-bit unsigned integers    #error Cannot determine a type for 32-bit unsigned integers
159  #endif  #endif
# Line 1126  extern BOOL _pcre_is_newline(con Line 1130  extern BOOL _pcre_is_newline(con
1130  extern int          _pcre_ord2utf8(int, uschar *);  extern int          _pcre_ord2utf8(int, uschar *);
1131  extern real_pcre   *_pcre_try_flipped(const real_pcre *, real_pcre *,  extern real_pcre   *_pcre_try_flipped(const real_pcre *, real_pcre *,
1132                        const pcre_study_data *, pcre_study_data *);                        const pcre_study_data *, pcre_study_data *);
 extern int          _pcre_ucp_findprop(const unsigned int, int *, int *);  
 extern unsigned int _pcre_ucp_othercase(const unsigned int);  
1133  extern int          _pcre_valid_utf8(const uschar *, int);  extern int          _pcre_valid_utf8(const uschar *, int);
1134  extern BOOL         _pcre_was_newline(const uschar *, int, const uschar *,  extern BOOL         _pcre_was_newline(const uschar *, int, const uschar *,
1135                        int *, BOOL);                        int *, BOOL);
1136  extern BOOL         _pcre_xclass(int, const uschar *);  extern BOOL         _pcre_xclass(int, const uschar *);
1137    
1138    
1139    /* Unicode character database (UCD) */
1140    
1141    typedef struct {
1142      uschar script;
1143      uschar chartype;
1144      pcre_int16 other_case;
1145    } ucd_record;
1146    
1147    extern const ucd_record  ucd_records[];
1148    extern const uschar      ucd_stage1[];
1149    extern const pcre_uint16 ucd_stage2[];
1150    extern const int ucp_gentype[];
1151    
1152    /* UCD access macros */
1153    
1154    #define UCD_BLOCK_SIZE 128
1155    #define GET_UCD(ch) (ucd_records + ucd_stage2[ucd_stage1[(ch) / UCD_BLOCK_SIZE] * \
1156            UCD_BLOCK_SIZE + ch % UCD_BLOCK_SIZE])
1157    
1158    #define UCD_CHARTYPE(ch)  GET_UCD(ch)->chartype
1159    #define UCD_SCRIPT(ch)    GET_UCD(ch)->script
1160    #define UCD_CATEGORY(ch)  ucp_gentype[UCD_CHARTYPE(ch)]
1161    #define UCD_OTHERCASE(ch) (ch + GET_UCD(ch)->other_case)
1162    
1163  #endif  #endif
1164    
1165  /* End of pcre_internal.h */  /* End of pcre_internal.h */

Legend:
Removed from v.348  
changed lines
  Added in v.349

webmaster@exim.org
ViewVC Help
Powered by ViewVC 1.1.12