File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -432,7 +432,7 @@ class InterpolatedRegularExpressionNode < Node
432
432
# Returns a numeric value that represents the flags that were used to create
433
433
# the regular expression.
434
434
def options
435
- o = flags & 0b111
435
+ o = flags & ( RegularExpressionFlags :: IGNORE_CASE | RegularExpressionFlags :: EXTENDED | RegularExpressionFlags :: MULTI_LINE )
436
436
o |= Regexp ::FIXEDENCODING if flags . anybits? ( RegularExpressionFlags ::EUC_JP | RegularExpressionFlags ::WINDOWS_31J | RegularExpressionFlags ::UTF_8 )
437
437
o |= Regexp ::NOENCODING if flags . anybits? ( RegularExpressionFlags ::ASCII_8BIT )
438
438
o
@@ -450,7 +450,7 @@ class RegularExpressionNode < Node
450
450
# Returns a numeric value that represents the flags that were used to create
451
451
# the regular expression.
452
452
def options
453
- o = flags & 0b111
453
+ o = flags & ( RegularExpressionFlags :: IGNORE_CASE | RegularExpressionFlags :: EXTENDED | RegularExpressionFlags :: MULTI_LINE )
454
454
o |= Regexp ::FIXEDENCODING if flags . anybits? ( RegularExpressionFlags ::EUC_JP | RegularExpressionFlags ::WINDOWS_31J | RegularExpressionFlags ::UTF_8 )
455
455
o |= Regexp ::NOENCODING if flags . anybits? ( RegularExpressionFlags ::ASCII_8BIT )
456
456
o
You can’t perform that action at this time.
0 commit comments