[1.9] Unicode characters in regexp in unicode-encoded file do not parse
-----------------------------------------------------------------------
Key: JRUBY-5301
URL: http://jira.codehaus.org/browse/JRUBY-5301
Project: JRuby
Issue Type: Bug
Components: Parser, Ruby 1.9
Reporter: Charles Oliver Nutter
Assignee: Thomas E Enebo
Fix For: JRuby 1.6
File:
{noformat}
# encoding: utf-8
/こ/u
{noformat}
Error:
{noformat}
~/projects/rails/activesupport ➔ jruby --1.9 -c multibyte_chars_test.rb
org.jruby.exceptions.RaiseException: (RegexpError) invalid multibyte character:
/ãã““/
~/projects/rails/activesupport ➔ jruby -Xbacktrace.style=raw --1.9 -c
multibyte_chars_test.rb
org.jruby.exceptions.RaiseException: (RegexpError) invalid multibyte character:
/ãã““/
at java.lang.Thread.getStackTrace(Thread.java:1503)
at org.jruby.RubyException.prepareBacktrace(RubyException.java:154)
at org.jruby.exceptions.RaiseException.preRaise(RaiseException.java:156)
at org.jruby.Ruby.newRaiseException(Ruby.java:3405)
at org.jruby.Ruby.newRegexpError(Ruby.java:3238)
at org.jruby.RubyRegexp.raiseRegexpError19(RubyRegexp.java:1017)
at org.jruby.RubyRegexp.raisePreprocessError(RubyRegexp.java:431)
at org.jruby.RubyRegexp.unescapeNonAscii(RubyRegexp.java:601)
at org.jruby.RubyRegexp.preprocess(RubyRegexp.java:671)
at org.jruby.RubyRegexp.preprocessCheck(RubyRegexp.java:678)
at
org.jruby.parser.ParserSupport.regexpFragmentCheck(ParserSupport.java:1617)
at org.jruby.parser.ParserSupport.newRegexpNode(ParserSupport.java:1630)
at org.jruby.parser.Ruby19Parser$295.execute(Ruby19Parser.java:3575)
at org.jruby.parser.Ruby19Parser.yyparse(Ruby19Parser.java:1477)
at org.jruby.parser.Ruby19Parser.yyparse(Ruby19Parser.java:1368)
at org.jruby.parser.Ruby19Parser.parse(Ruby19Parser.java:4237)
at org.jruby.parser.Parser.parse(Parser.java:112)
at org.jruby.parser.Parser.parse(Parser.java:94)
at org.jruby.Ruby.parseFile(Ruby.java:2290)
at org.jruby.Ruby.parseFile(Ruby.java:2295)
at org.jruby.Ruby.parseFromMain(Ruby.java:444)
at org.jruby.Main.run(Main.java:255)
at org.jruby.Main.run(Main.java:144)
at org.jruby.Main.main(Main.java:113)
{noformat}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email