Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #From http://ruby-doc.org/core-1.9.3/Regexp.html
- /[a-w&&[^c-g]z]/ # ([a-w] AND ([^c-g] OR z))
- # This is equivalent to:
- /[abh-w]/
- # but running this via irb gives:
- >> /[a-w&&[^c-g]z]/
- (irb):60: warning: character class has `[' without escape
- (irb):60: warning: regexp has `]' without escape
- # but seems ok via rubular.com. Why?!!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement