Re: Named-capture regex syntax
[p5sagit/p5-mst-13.2.git] / regcomp.h
index ce96da1..7df47d3 100644 (file)
--- a/regcomp.h
+++ b/regcomp.h
@@ -103,10 +103,14 @@ typedef struct regexp_paren_ofs {
 } regexp_paren_ofs;
 
  typedef struct regexp_internal {
-        regexp_paren_ofs *swap; /* Swap copy of *startp / *endp */
+#ifdef DEBUGGING
+        int name_list_idx;     /* Optional data index of an array of paren names */
+#endif
+
        U32 *offsets;           /* offset annotations 20001228 MJD 
                                    data about mapping the program to the 
                                    string*/
+        regexp_paren_ofs *swap; /* Swap copy of *startp / *endp */                                   
         regnode *regstclass;    /* Optional startclass as identified or constructed
                                    by the optimiser */
         struct reg_data *data; /* Additional miscellaneous data used by the program.
@@ -484,6 +488,8 @@ struct reg_data {
     void* data[1];
 };
 
+/* Code in S_to_utf8_substr() and S_to_byte_substr() in regexec.c accesses
+   anchored* and float* via array indexes 0 and 1.  */
 #define anchored_substr substrs->data[0].substr
 #define anchored_utf8 substrs->data[0].utf8_substr
 #define anchored_offset substrs->data[0].min_offset