This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
[perl #56880] Allow v10 as a label or package name
[perl5.git] / regexp.h
index 1fe4c3f..c515667 100644 (file)
--- a/regexp.h
+++ b/regexp.h
@@ -395,11 +395,14 @@ get_regex_charset_name(const U32 flags, STRLEN* const lenp)
 #define RXf_INTUIT_TAIL        (1<<(RXf_BASE_SHIFT+14))
 
 /*
-  Set in Perl_pmruntime if op_flags & OPf_SPECIAL, i.e. split. Will
-  be used by regex engines to check whether they should set
-  RXf_SKIPWHITE
+  This used to be set in Perl_pmruntime if op_flags & OPf_SPECIAL, i.e.
+  split.  It was used by the regex engine to check whether it should set
+  RXf_SKIPWHITE.  Regexp plugins on CPAN also have done the same thing
+  historically, so we leave this flag defined, even though it is never set.
 */
-#define RXf_SPLIT              (1<<(RXf_BASE_SHIFT+15))
+#if !defined(PERL_CORE) || defined(PERL_IN_DUMP_C)
+# define RXf_SPLIT             (1<<(RXf_BASE_SHIFT+15))
+#endif
 
 #define RXf_USE_INTUIT         (RXf_USE_INTUIT_NOML|RXf_USE_INTUIT_ML)
 
@@ -414,7 +417,10 @@ get_regex_charset_name(const U32 flags, STRLEN* const lenp)
 
 /* Flags indicating special patterns */
 #define RXf_START_ONLY         (1<<(RXf_BASE_SHIFT+19)) /* Pattern is /^/ */
-#define RXf_SKIPWHITE          (1<<(RXf_BASE_SHIFT+20)) /* Pattern is for a split " " */
+/* No longer used, but CPAN modules still mention it. */
+#if !defined(PERL_CORE) || defined(PERL_IN_DUMP_C)
+# define RXf_SKIPWHITE         (1<<(RXf_BASE_SHIFT+20)) /* Pattern is for a split " " */
+#endif
 #define RXf_WHITE              (1<<(RXf_BASE_SHIFT+21)) /* Pattern is /\s+/ */
 #define RXf_NULL               (1U<<(RXf_BASE_SHIFT+22)) /* Pattern is // */
 #if RXf_BASE_SHIFT+22 > 31