/[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 691 by ph10, Sun Sep 11 14:31:21 2011 UTC revision 835 by ph10, Wed Dec 28 16:10:09 2011 UTC
# Line 594  compatibility. */ Line 594  compatibility. */
594  #define PCRE_STARTLINE     0x0008  /* start after \n for multiline */  #define PCRE_STARTLINE     0x0008  /* start after \n for multiline */
595  #define PCRE_JCHANGED      0x0010  /* j option used in regex */  #define PCRE_JCHANGED      0x0010  /* j option used in regex */
596  #define PCRE_HASCRORLF     0x0020  /* explicit \r or \n in pattern */  #define PCRE_HASCRORLF     0x0020  /* explicit \r or \n in pattern */
597    #define PCRE_HASTHEN       0x0040  /* pattern contains (*THEN) */
598    
599  /* Flags for the "extra" block produced by pcre_study(). */  /* Flags for the "extra" block produced by pcre_study(). */
600    
# Line 1251  value such as \n. They must have non-zer Line 1252  value such as \n. They must have non-zer
1252  their negation. Also, they must appear in the same order as in the opcode  their negation. Also, they must appear in the same order as in the opcode
1253  definitions below, up to ESC_z. There's a dummy for OP_ALLANY because it  definitions below, up to ESC_z. There's a dummy for OP_ALLANY because it
1254  corresponds to "." in DOTALL mode rather than an escape sequence. It is also  corresponds to "." in DOTALL mode rather than an escape sequence. It is also
1255  used for [^] in JavaScript compatibility mode. In non-DOTALL mode, "." behaves  used for [^] in JavaScript compatibility mode, and for \C in non-utf8 mode. In
1256  like \N.  non-DOTALL mode, "." behaves like \N.
1257    
1258  The special values ESC_DU, ESC_du, etc. are used instead of ESC_D, ESC_d, etc.  The special values ESC_DU, ESC_du, etc. are used instead of ESC_D, ESC_d, etc.
1259  when PCRE_UCP is set, when replacement of \d etc by \p sequences is required.  when PCRE_UCP is set, when replacement of \d etc by \p sequences is required.
# Line 1455  enum { Line 1456  enum {
1456    OP_ASSERTBACK,     /* 121 Positive lookbehind */    OP_ASSERTBACK,     /* 121 Positive lookbehind */
1457    OP_ASSERTBACK_NOT, /* 122 Negative lookbehind */    OP_ASSERTBACK_NOT, /* 122 Negative lookbehind */
1458    
1459    /* ONCE, BRA, BRAPOS, CBRA, CBRAPOS, and COND must come immediately after the    /* ONCE, ONCE_NC, BRA, BRAPOS, CBRA, CBRAPOS, and COND must come immediately
1460    assertions, with ONCE first, as there's a test for >= ONCE for a subpattern    after the assertions, with ONCE first, as there's a test for >= ONCE for a
1461    that isn't an assertion. The POS versions must immediately follow the non-POS    subpattern that isn't an assertion. The POS versions must immediately follow
1462    versions in each case. */    the non-POS versions in each case. */
1463    
1464    OP_ONCE,           /* 123 Atomic group */    OP_ONCE,           /* 123 Atomic group, contains captures */
1465    OP_BRA,            /* 124 Start of non-capturing bracket */    OP_ONCE_NC,        /* 124 Atomic group containing no captures */
1466    OP_BRAPOS,         /* 125 Ditto, with unlimited, possessive repeat */    OP_BRA,            /* 125 Start of non-capturing bracket */
1467    OP_CBRA,           /* 126 Start of capturing bracket */    OP_BRAPOS,         /* 126 Ditto, with unlimited, possessive repeat */
1468    OP_CBRAPOS,        /* 127 Ditto, with unlimited, possessive repeat */    OP_CBRA,           /* 127 Start of capturing bracket */
1469    OP_COND,           /* 128 Conditional group */    OP_CBRAPOS,        /* 128 Ditto, with unlimited, possessive repeat */
1470      OP_COND,           /* 129 Conditional group */
1471    
1472    /* These five must follow the previous five, in the same order. There's a    /* These five must follow the previous five, in the same order. There's a
1473    check for >= SBRA to distinguish the two sets. */    check for >= SBRA to distinguish the two sets. */
1474    
1475    OP_SBRA,           /* 129 Start of non-capturing bracket, check empty  */    OP_SBRA,           /* 130 Start of non-capturing bracket, check empty  */
1476    OP_SBRAPOS,        /* 130 Ditto, with unlimited, possessive repeat */    OP_SBRAPOS,        /* 131 Ditto, with unlimited, possessive repeat */
1477    OP_SCBRA,          /* 131 Start of capturing bracket, check empty */    OP_SCBRA,          /* 132 Start of capturing bracket, check empty */
1478    OP_SCBRAPOS,       /* 132 Ditto, with unlimited, possessive repeat */    OP_SCBRAPOS,       /* 133 Ditto, with unlimited, possessive repeat */
1479    OP_SCOND,          /* 133 Conditional group, check empty */    OP_SCOND,          /* 134 Conditional group, check empty */
1480    
1481    /* The next two pairs must (respectively) be kept together. */    /* The next two pairs must (respectively) be kept together. */
1482    
1483    OP_CREF,           /* 134 Used to hold a capture number as condition */    OP_CREF,           /* 135 Used to hold a capture number as condition */
1484    OP_NCREF,          /* 135 Same, but generated by a name reference*/    OP_NCREF,          /* 136 Same, but generated by a name reference*/
1485    OP_RREF,           /* 136 Used to hold a recursion number as condition */    OP_RREF,           /* 137 Used to hold a recursion number as condition */
1486    OP_NRREF,          /* 137 Same, but generated by a name reference*/    OP_NRREF,          /* 138 Same, but generated by a name reference*/
1487    OP_DEF,            /* 138 The DEFINE condition */    OP_DEF,            /* 139 The DEFINE condition */
1488    
1489    OP_BRAZERO,        /* 139 These two must remain together and in this */    OP_BRAZERO,        /* 140 These two must remain together and in this */
1490    OP_BRAMINZERO,     /* 140 order. */    OP_BRAMINZERO,     /* 141 order. */
1491    OP_BRAPOSZERO,     /* 141 */    OP_BRAPOSZERO,     /* 142 */
1492    
1493    /* These are backtracking control verbs */    /* These are backtracking control verbs */
1494    
1495    OP_MARK,           /* 142 always has an argument */    OP_MARK,           /* 143 always has an argument */
1496    OP_PRUNE,          /* 143 */    OP_PRUNE,          /* 144 */
1497    OP_PRUNE_ARG,      /* 144 same, but with argument */    OP_PRUNE_ARG,      /* 145 same, but with argument */
1498    OP_SKIP,           /* 145 */    OP_SKIP,           /* 146 */
1499    OP_SKIP_ARG,       /* 146 same, but with argument */    OP_SKIP_ARG,       /* 147 same, but with argument */
1500    OP_THEN,           /* 147 */    OP_THEN,           /* 148 */
1501    OP_THEN_ARG,       /* 148 same, but with argument */    OP_THEN_ARG,       /* 149 same, but with argument */
1502    OP_COMMIT,         /* 149 */    OP_COMMIT,         /* 150 */
1503    
1504    /* These are forced failure and success verbs */    /* These are forced failure and success verbs */
1505    
1506    OP_FAIL,           /* 150 */    OP_FAIL,           /* 151 */
1507    OP_ACCEPT,         /* 151 */    OP_ACCEPT,         /* 152 */
1508    OP_ASSERT_ACCEPT,  /* 152 Used inside assertions */    OP_ASSERT_ACCEPT,  /* 153 Used inside assertions */
1509    OP_CLOSE,          /* 153 Used before OP_ACCEPT to close open captures */    OP_CLOSE,          /* 154 Used before OP_ACCEPT to close open captures */
1510    
1511    /* This is used to skip a subpattern with a {0} quantifier */    /* This is used to skip a subpattern with a {0} quantifier */
1512    
1513    OP_SKIPZERO,       /* 154 */    OP_SKIPZERO,       /* 155 */
1514    
1515    /* This is not an opcode, but is used to check that tables indexed by opcode    /* This is not an opcode, but is used to check that tables indexed by opcode
1516    are the correct length, in order to catch updating errors - there have been    are the correct length, in order to catch updating errors - there have been
# Line 1552  some cases doesn't actually use these na Line 1554  some cases doesn't actually use these na
1554    "Recurse", "Callout",                                           \    "Recurse", "Callout",                                           \
1555    "Alt", "Ket", "KetRmax", "KetRmin", "KetRpos",                  \    "Alt", "Ket", "KetRmax", "KetRmin", "KetRpos",                  \
1556    "Reverse", "Assert", "Assert not", "AssertB", "AssertB not",    \    "Reverse", "Assert", "Assert not", "AssertB", "AssertB not",    \
1557    "Once",                                                         \    "Once", "Once_NC",                                              \
1558    "Bra", "BraPos", "CBra", "CBraPos",                             \    "Bra", "BraPos", "CBra", "CBraPos",                             \
1559    "Cond",                                                         \    "Cond",                                                         \
1560    "SBra", "SBraPos", "SCBra", "SCBraPos",                         \    "SBra", "SBraPos", "SCBra", "SCBraPos",                         \
# Line 1626  in UTF-8 mode. The code that uses this t Line 1628  in UTF-8 mode. The code that uses this t
1628    1+LINK_SIZE,                   /* Assert behind                          */ \    1+LINK_SIZE,                   /* Assert behind                          */ \
1629    1+LINK_SIZE,                   /* Assert behind not                      */ \    1+LINK_SIZE,                   /* Assert behind not                      */ \
1630    1+LINK_SIZE,                   /* ONCE                                   */ \    1+LINK_SIZE,                   /* ONCE                                   */ \
1631      1+LINK_SIZE,                   /* ONCE_NC                                */ \
1632    1+LINK_SIZE,                   /* BRA                                    */ \    1+LINK_SIZE,                   /* BRA                                    */ \
1633    1+LINK_SIZE,                   /* BRAPOS                                 */ \    1+LINK_SIZE,                   /* BRAPOS                                 */ \
1634    3+LINK_SIZE,                   /* CBRA                                   */ \    3+LINK_SIZE,                   /* CBRA                                   */ \
# Line 1642  in UTF-8 mode. The code that uses this t Line 1645  in UTF-8 mode. The code that uses this t
1645    1, 1, 1,                       /* BRAZERO, BRAMINZERO, BRAPOSZERO        */ \    1, 1, 1,                       /* BRAZERO, BRAMINZERO, BRAPOSZERO        */ \
1646    3, 1, 3,                       /* MARK, PRUNE, PRUNE_ARG                 */ \    3, 1, 3,                       /* MARK, PRUNE, PRUNE_ARG                 */ \
1647    1, 3,                          /* SKIP, SKIP_ARG                         */ \    1, 3,                          /* SKIP, SKIP_ARG                         */ \
1648    1+LINK_SIZE, 3+LINK_SIZE,      /* THEN, THEN_ARG                         */ \    1, 3,                          /* THEN, THEN_ARG                         */ \
1649    1, 1, 1, 1,                    /* COMMIT, FAIL, ACCEPT, ASSERT_ACCEPT    */ \    1, 1, 1, 1,                    /* COMMIT, FAIL, ACCEPT, ASSERT_ACCEPT    */ \
1650    3, 1                           /* CLOSE, SKIPZERO  */    3, 1                           /* CLOSE, SKIPZERO  */
1651    
# Line 1662  enum { ERR0,  ERR1,  ERR2,  ERR3,  ERR4, Line 1665  enum { ERR0,  ERR1,  ERR2,  ERR3,  ERR4,
1665         ERR40, ERR41, ERR42, ERR43, ERR44, ERR45, ERR46, ERR47, ERR48, ERR49,         ERR40, ERR41, ERR42, ERR43, ERR44, ERR45, ERR46, ERR47, ERR48, ERR49,
1666         ERR50, ERR51, ERR52, ERR53, ERR54, ERR55, ERR56, ERR57, ERR58, ERR59,         ERR50, ERR51, ERR52, ERR53, ERR54, ERR55, ERR56, ERR57, ERR58, ERR59,
1667         ERR60, ERR61, ERR62, ERR63, ERR64, ERR65, ERR66, ERR67, ERR68, ERR69,         ERR60, ERR61, ERR62, ERR63, ERR64, ERR65, ERR66, ERR67, ERR68, ERR69,
1668         ERRCOUNT };         ERR70, ERRCOUNT };
1669    
1670  /* The real format of the start of the pcre block; the index of names and the  /* The real format of the start of the pcre block; the index of names and the
1671  code vector run on as long as necessary after the end. We store an explicit  code vector run on as long as necessary after the end. We store an explicit
# Line 1820  typedef struct match_data { Line 1823  typedef struct match_data {
1823    BOOL   notempty_atstart;      /* Empty string match at start not wanted */    BOOL   notempty_atstart;      /* Empty string match at start not wanted */
1824    BOOL   hitend;                /* Hit the end of the subject at some point */    BOOL   hitend;                /* Hit the end of the subject at some point */
1825    BOOL   bsr_anycrlf;           /* \R is just any CRLF, not full Unicode */    BOOL   bsr_anycrlf;           /* \R is just any CRLF, not full Unicode */
1826      BOOL   hasthen;               /* Pattern contains (*THEN) */
1827    const  uschar *start_code;    /* For use when recursing */    const  uschar *start_code;    /* For use when recursing */
1828    USPTR  start_subject;         /* Start of the subject string */    USPTR  start_subject;         /* Start of the subject string */
1829    USPTR  end_subject;           /* End of the subject string */    USPTR  end_subject;           /* End of the subject string */

Legend:
Removed from v.691  
changed lines
  Added in v.835

  ViewVC Help
Powered by ViewVC 1.1.5