/[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 1128 by chpe, Thu Oct 18 18:35:08 2012 UTC revision 1187 by zherczeg, Mon Oct 29 11:30:45 2012 UTC
# Line 53  depending on the PRIV macro. */ Line 53  depending on the PRIV macro. */
53  #endif  #endif
54    
55  /* PCRE is compiled as an 8 bit library if it is not requested otherwise. */  /* PCRE is compiled as an 8 bit library if it is not requested otherwise. */
56    
57  #if !defined COMPILE_PCRE16 && !defined COMPILE_PCRE32  #if !defined COMPILE_PCRE16 && !defined COMPILE_PCRE32
58  #define COMPILE_PCRE8  #define COMPILE_PCRE8
59  #endif  #endif
# Line 111  setjmp and stdarg are used is when NO_RE Line 112  setjmp and stdarg are used is when NO_RE
112  #include <stdlib.h>  #include <stdlib.h>
113  #include <string.h>  #include <string.h>
114    
115    /* Valgrind (memcheck) support */
116    
117    #ifdef SUPPORT_VALGRIND
118    #include <valgrind/memcheck.h>
119    #endif
120    
121  /* When compiling a DLL for Windows, the exported symbols have to be declared  /* When compiling a DLL for Windows, the exported symbols have to be declared
122  using some MS magic. I found some useful information on this web page:  using some MS magic. I found some useful information on this web page:
123  http://msdn2.microsoft.com/en-us/library/y4h7bcy6(VS.80).aspx. According to the  http://msdn2.microsoft.com/en-us/library/y4h7bcy6(VS.80).aspx. According to the
# Line 214  stdint.h is available, include it; it ma Line 221  stdint.h is available, include it; it ma
221  have stdint.h (e.g. Solaris) may have inttypes.h. The macro int64_t may be set  have stdint.h (e.g. Solaris) may have inttypes.h. The macro int64_t may be set
222  by "configure". */  by "configure". */
223    
224  #if HAVE_STDINT_H  #if defined HAVE_STDINT_H
225  #include <stdint.h>  #include <stdint.h>
226  #elif HAVE_INTTYPES_H  #elif defined HAVE_INTTYPES_H
227  #include <inttypes.h>  #include <inttypes.h>
228  #endif  #endif
229    
# Line 522  capturing parenthesis numbers in back re Line 529  capturing parenthesis numbers in back re
529  #define PUT2(a,n,d)   \  #define PUT2(a,n,d)   \
530    a[n] = (d) >> 8; \    a[n] = (d) >> 8; \
531    a[(n)+1] = (d) & 255    a[(n)+1] = (d) & 255
532    
533    /* For reasons that I do not understand, the expression in this GET2 macro is
534    treated by gcc as a signed expression, even when a is declared as unsigned. It
535    seems that any kind of arithmetic results in a signed value. */
536    
537  #define GET2(a,n) \  #define GET2(a,n) \
538    (((a)[n] << 8) | (a)[(n)+1])    (unsigned int)(((a)[n] << 8) | (a)[(n)+1])
539    
540  #elif defined COMPILE_PCRE16  #elif defined COMPILE_PCRE16
541    
# Line 1172  time, run time, or study time, respectiv Line 1183  time, run time, or study time, respectiv
1183     (PCRE_STUDY_JIT_COMPILE|PCRE_STUDY_JIT_PARTIAL_SOFT_COMPILE| \     (PCRE_STUDY_JIT_COMPILE|PCRE_STUDY_JIT_PARTIAL_SOFT_COMPILE| \
1184      PCRE_STUDY_JIT_PARTIAL_HARD_COMPILE|PCRE_STUDY_EXTRA_NEEDED)      PCRE_STUDY_JIT_PARTIAL_HARD_COMPILE|PCRE_STUDY_EXTRA_NEEDED)
1185    
1186    #define PUBLIC_JIT_EXEC_OPTIONS \
1187       (PCRE_NO_UTF8_CHECK|PCRE_NOTBOL|PCRE_NOTEOL|PCRE_NOTEMPTY|\
1188        PCRE_NOTEMPTY_ATSTART|PCRE_PARTIAL_SOFT|PCRE_PARTIAL_HARD)
1189    
1190  /* Magic number to provide a small check against being handed junk. */  /* Magic number to provide a small check against being handed junk. */
1191    
1192  #define MAGIC_NUMBER  0x50435245UL   /* 'PCRE' */  #define MAGIC_NUMBER  0x50435245UL   /* 'PCRE' */
# Line 1275  a positive value. */ Line 1290  a positive value. */
1290    
1291  /* The remaining definitions work in both environments. */  /* The remaining definitions work in both environments. */
1292    
1293    #define CHAR_NULL                   '\0'
1294  #define CHAR_HT                     '\t'  #define CHAR_HT                     '\t'
1295  #define CHAR_VT                     '\v'  #define CHAR_VT                     '\v'
1296  #define CHAR_FF                     '\f'  #define CHAR_FF                     '\f'
# Line 1544  only. */ Line 1560  only. */
1560  #define CHAR_ESC                    '\033'  #define CHAR_ESC                    '\033'
1561  #define CHAR_DEL                    '\177'  #define CHAR_DEL                    '\177'
1562    
1563    #define CHAR_NULL                   '\0'
1564  #define CHAR_SPACE                  '\040'  #define CHAR_SPACE                  '\040'
1565  #define CHAR_EXCLAMATION_MARK       '\041'  #define CHAR_EXCLAMATION_MARK       '\041'
1566  #define CHAR_QUOTATION_MARK         '\042'  #define CHAR_QUOTATION_MARK         '\042'
# Line 2393  typedef struct compile_data { Line 2410  typedef struct compile_data {
2410    int  names_found;                 /* Number of entries so far */    int  names_found;                 /* Number of entries so far */
2411    int  name_entry_size;             /* Size of each entry */    int  name_entry_size;             /* Size of each entry */
2412    int  workspace_size;              /* Size of workspace */    int  workspace_size;              /* Size of workspace */
2413    int  bracount;                    /* Count of capturing parens as we compile */    unsigned int  bracount;           /* Count of capturing parens as we compile */
2414    int  final_bracount;              /* Saved value after first pass */    int  final_bracount;              /* Saved value after first pass */
2415    int  max_lookbehind;              /* Maximum lookbehind (characters) */    int  max_lookbehind;              /* Maximum lookbehind (characters) */
2416    int  top_backref;                 /* Maximum back reference */    int  top_backref;                 /* Maximum back reference */
# Line 2423  call within the pattern; used by pcre_ex Line 2440  call within the pattern; used by pcre_ex
2440    
2441  typedef struct recursion_info {  typedef struct recursion_info {
2442    struct recursion_info *prevrec; /* Previous recursion record (or NULL) */    struct recursion_info *prevrec; /* Previous recursion record (or NULL) */
2443    int group_num;                  /* Number of group that was called */    unsigned int group_num;         /* Number of group that was called */
2444    int *offset_save;               /* Pointer to start of saved offsets */    int *offset_save;               /* Pointer to start of saved offsets */
2445    int saved_max;                  /* Number of saved offsets */    int saved_max;                  /* Number of saved offsets */
2446    PCRE_PUCHAR subject_position;   /* Position at start of recursion */    PCRE_PUCHAR subject_position;   /* Position at start of recursion */
# Line 2681  extern int               PRIV(strcmp_uc_ Line 2698  extern int               PRIV(strcmp_uc_
2698  extern const pcre_uchar *PRIV(find_bracket)(const pcre_uchar *, BOOL, int);  extern const pcre_uchar *PRIV(find_bracket)(const pcre_uchar *, BOOL, int);
2699  extern BOOL              PRIV(is_newline)(PCRE_PUCHAR, int, PCRE_PUCHAR,  extern BOOL              PRIV(is_newline)(PCRE_PUCHAR, int, PCRE_PUCHAR,
2700                             int *, BOOL);                             int *, BOOL);
2701  extern int               PRIV(ord2utf)(pcre_uint32, pcre_uchar *);  extern unsigned int      PRIV(ord2utf)(pcre_uint32, pcre_uchar *);
2702  extern int               PRIV(valid_utf)(PCRE_PUCHAR, int, int *);  extern int               PRIV(valid_utf)(PCRE_PUCHAR, int, int *);
2703  extern BOOL              PRIV(was_newline)(PCRE_PUCHAR, int, PCRE_PUCHAR,  extern BOOL              PRIV(was_newline)(PCRE_PUCHAR, int, PCRE_PUCHAR,
2704                             int *, BOOL);                             int *, BOOL);
# Line 2690  extern BOOL              PRIV(xclass)(pc Line 2707  extern BOOL              PRIV(xclass)(pc
2707  #ifdef SUPPORT_JIT  #ifdef SUPPORT_JIT
2708  extern void              PRIV(jit_compile)(const REAL_PCRE *,  extern void              PRIV(jit_compile)(const REAL_PCRE *,
2709                             PUBL(extra) *, int);                             PUBL(extra) *, int);
2710  extern int               PRIV(jit_exec)(const REAL_PCRE *, const PUBL(extra) *,  extern int               PRIV(jit_exec)(const PUBL(extra) *,
2711                             const pcre_uchar *, int, int, int, int *, int);                             const pcre_uchar *, int, int, int, int *, int);
2712  extern void              PRIV(jit_free)(void *);  extern void              PRIV(jit_free)(void *);
2713  extern int               PRIV(jit_get_size)(void *);  extern int               PRIV(jit_get_size)(void *);

Legend:
Removed from v.1128  
changed lines
  Added in v.1187

  ViewVC Help
Powered by ViewVC 1.1.5