Class: Regexp
- Inherits:
-
Object
- Object
- Regexp
- Defined in:
- lib/ver/plist.rb
Overview
Define some magic constants that aren’t available but may be returned from Regexp#options so we can make sure that roundtrip via PP works.
1.9.2 actually defines Regexp::FIXEDENCODING, but there’s no release yet, so we simply assume the values from the Ruby C source (which means this might not work on any other implementation). Hopefully nobody tries to convert textmate bundles unless they are on MRI 1.9.1 ;)
Constant Summary collapse
- NO_ENCODING =
//n.
Instance Method Summary collapse
-
#inspect ⇒ Object
Take into account //n option.
- #original_inspect ⇒ Object
Instance Method Details
#inspect ⇒ Object
Take into account //n option
20 21 22 23 24 25 26 |
# File 'lib/ver/plist.rb', line 20 def inspect if & NO_ENCODING == 0 original_inspect else original_inspect << 'n' end end |
#original_inspect ⇒ Object
17 |
# File 'lib/ver/plist.rb', line 17 alias original_inspect inspect |