[ragel-users] UTF-8 problems with Java

aslak hellesoy aslak.hellesoy at gmail.com
Tue Nov 24 20:39:24 UTC 2009


Hi there,

First of all - thanks a lot for Ragel - it's awesome. We're using it
to implement a fast parser for http://cukes.info/.

I'm having problems scanning text when the keywords in the .rl file
uses UTF-8 characters.
This is easy to reproduce with the java1.rl example:
http://svn.complang.org/ragel/trunk/test/java1.rl

$ ragel -J java1.rl && javac java1.java && java java1
ACCEPT
FAIL
FAIL

Now, replace hello with hællø in both the machine declaration (line
15) and the main method (line 38):

$ ragel -J java1.rl && javac java1.java && java java1
FAIL
FAIL
FAIL

Is this a Ragel bug, or am I doing something wrong?
I'm using Ragel 6.5, OS X Leopard and Java 1.5.

Cheers,
Aslak




More information about the ragel-users mailing list