This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Move the duplicated subroutine tab() into regen_lib.pl
[perl5.git] / op_reg_common.h
index c8a3518..f509650 100644 (file)
@@ -40,7 +40,8 @@
 typedef enum {
     REGEX_DEPENDS_CHARSET = 0,
     REGEX_LOCALE_CHARSET,
-    REGEX_UNICODE_CHARSET
+    REGEX_UNICODE_CHARSET,
+    REGEX_ASCII_RESTRICTED_CHARSET
 } regex_charset;
 
 #define _RXf_PMf_CHARSET_SHIFT ((RXf_PMf_STD_PMMOD_SHIFT)+5)
@@ -72,7 +73,7 @@ get_regex_charset(const U32 flags)
 {
     /* Returns the enum corresponding to the character set in 'flags' */
 
-    return (flags & RXf_PMf_CHARSET) >> _RXf_PMf_CHARSET_SHIFT;
+    return (regex_charset) ((flags & RXf_PMf_CHARSET) >> _RXf_PMf_CHARSET_SHIFT);
 }
 
 /* Next available bit after the above.  Name begins with '_' so won't be