summaryrefslogtreecommitdiff
path: root/perl.h
diff options
context:
space:
mode:
authorYves Orton <demerphq@gmail.com>2007-01-13 18:18:01 +0100
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>2007-01-15 16:37:21 +0000
commita20207d7c00bd54d6d2718961a96cd5c7ed1e37b (patch)
tree0b43606006e1c20c7552202ed54244b4d5525013 /perl.h
parentcde0cee5716418bb58782f073048ee9685ed2368 (diff)
downloadperl-a20207d7c00bd54d6d2718961a96cd5c7ed1e37b.tar.gz
Re: [PATCH] Add support for /k modfier for matching along with ${^PREMATCH}, ${^MATCH}, ${^POSTMATCH}
Message-ID: <9b18b3110701130818h6badbd3o1b38f2660d258173@mail.gmail.com> macroize regexp modifiers p4raw-id: //depot/perl@29834
Diffstat (limited to 'perl.h')
-rw-r--r--perl.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/perl.h b/perl.h
index 019335f497..d8cdfeb139 100644
--- a/perl.h
+++ b/perl.h
@@ -228,6 +228,33 @@
: (REGEXP *)NULL)
#endif
+
+/* chars and strings used as regex pattern modifiers
+ * Singlular is a 'c'har, plural is a "string"
+ */
+#define EXEC_PAT_MOD 'e'
+#define KEEPCOPY_PAT_MOD 'k'
+#define ONCE_PAT_MOD 'o'
+#define GLOBAL_PAT_MOD 'g'
+#define CONTINUE_PAT_MOD 'c'
+#define MULTILINE_PAT_MOD 'm'
+#define SINGLE_PAT_MOD 's'
+#define IGNORE_PAT_MOD 'i'
+#define XTENDED_PAT_MOD 'x'
+
+#define ONCE_PAT_MODS "o"
+#define KEEPCOPY_PAT_MODS "k"
+#define EXEC_PAT_MODS "e"
+#define LOOP_PAT_MODS "gc"
+
+#define STD_PAT_MODS "msix"
+
+#define EXT_PAT_MODS ONCE_PAT_MODS KEEPCOPY_PAT_MODS
+#define QR_PAT_MODS STD_PAT_MODS EXT_PAT_MODS
+#define M_PAT_MODS QR_PAT_MODS LOOP_PAT_MODS
+#define S_PAT_MODS M_PAT_MODS EXEC_PAT_MODS
+
+
/*
* Because of backward compatibility reasons the PERL_UNUSED_DECL
* cannot be changed from postfix to PERL_UNUSED_DECL(x). Sigh.