Issue #7593 has been reported by pwim (Paul McMahon).

----------------------------------------
Bug #7593: File encoding needs to be specified when using {Katakana} character property
https://bugs.ruby-lang.org/issues/7593

Author: pwim (Paul McMahon)
Status: Open
Priority: Normal
Assignee: 
Category: 
Target version: 
ruby -v: ruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-darwin12.0.0]


Creating a file with only the following line in it:

/\p{Katakana}/

will raise the error

katakana.rb:1: invalid character property name {Katakana}: /\p{Katakana}/

This can be resolved by specifying

# encoding: UTF-8

However, it was not obvious to me that this was needed.


-- 
http://bugs.ruby-lang.org/