aboutsummaryrefslogtreecommitdiffstats
path: root/re.c
diff options
context:
space:
mode:
Diffstat (limited to 're.c')
-rw-r--r--re.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/re.c b/re.c
index fb05e2e892..fc9e830131 100644
--- a/re.c
+++ b/re.c
@@ -937,7 +937,7 @@ rb_match_busy(VALUE match)
static VALUE
rb_reg_fixed_encoding_p(VALUE re)
{
- if (ENCODING_GET(re) != 0 || FL_TEST(re, KCODE_FIXED))
+ if (!ENCODING_IS_ASCII8BIT(re) || FL_TEST(re, KCODE_FIXED))
return Qtrue;
else
return Qfalse;