summaryrefslogtreecommitdiff
path: root/regcomp.h
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2019-08-26 11:53:06 -0600
committerKarl Williamson <khw@cpan.org>2019-08-26 12:00:19 -0600
commitfd41b2d1cbe9a90b3c4c9c4f4fe1b72ac724fdbb (patch)
tree4080f51e25cf3de1cbfac5ced9d644f179cf7315 /regcomp.h
parent9aae37edc3bbb46850997959dce7432265b1e74a (diff)
downloadperl-fd41b2d1cbe9a90b3c4c9c4f4fe1b72ac724fdbb.tar.gz
Add ability to dump pre-optimized compiled pattern
in qr//
Diffstat (limited to 'regcomp.h')
-rw-r--r--regcomp.h22
1 files changed, 13 insertions, 9 deletions
diff --git a/regcomp.h b/regcomp.h
index aaf65c3331..62f4398ed1 100644
--- a/regcomp.h
+++ b/regcomp.h
@@ -997,16 +997,17 @@ re.pm, especially to the documentation.
#define RE_DEBUG_EXECUTE_TRIE 0x000400
/* Extra */
-#define RE_DEBUG_EXTRA_MASK 0xFF0000
-#define RE_DEBUG_EXTRA_TRIE 0x010000
-#define RE_DEBUG_EXTRA_OFFSETS 0x020000
-#define RE_DEBUG_EXTRA_OFFDEBUG 0x040000
-#define RE_DEBUG_EXTRA_STATE 0x080000
-#define RE_DEBUG_EXTRA_OPTIMISE 0x100000
-#define RE_DEBUG_EXTRA_BUFFERS 0x400000
-#define RE_DEBUG_EXTRA_GPOS 0x800000
+#define RE_DEBUG_EXTRA_MASK 0x1FF0000
+#define RE_DEBUG_EXTRA_TRIE 0x0010000
+#define RE_DEBUG_EXTRA_OFFSETS 0x0020000
+#define RE_DEBUG_EXTRA_OFFDEBUG 0x0040000
+#define RE_DEBUG_EXTRA_STATE 0x0080000
+#define RE_DEBUG_EXTRA_OPTIMISE 0x0100000
+#define RE_DEBUG_EXTRA_BUFFERS 0x0400000
+#define RE_DEBUG_EXTRA_GPOS 0x0800000
+#define RE_DEBUG_EXTRA_DUMP_PRE_OPTIMIZE 0x1000000
/* combined */
-#define RE_DEBUG_EXTRA_STACK 0x280000
+#define RE_DEBUG_EXTRA_STACK 0x0280000
#define RE_DEBUG_FLAG(x) (re_debug_flags & x)
/* Compile */
@@ -1063,6 +1064,9 @@ re.pm, especially to the documentation.
#define DEBUG_GPOS_r(x) DEBUG_r( \
if (DEBUG_v_TEST || (re_debug_flags & RE_DEBUG_EXTRA_GPOS)) x )
+#define DEBUG_DUMP_PRE_OPTIMIZE_r(x) DEBUG_r( \
+ if (DEBUG_v_TEST || (re_debug_flags & RE_DEBUG_EXTRA_DUMP_PRE_OPTIMIZE)) x )
+
/* initialization */
/* get_sv() can return NULL during global destruction. */
#define GET_RE_DEBUG_FLAGS DEBUG_r({ \