[ragel-users] 0x0E..0xFF produces "lower end of range is greater then upper end"

Jan Kundrát jkt at flaska.net
Mon Oct 21 15:21:40 UTC 2013


On Monday, 21 October 2013 17:17:57 CEST, Iñaki Baz Castillo wrote:
> The following modification in the grammar fixes it:
>
>   ( 0x01..0x09 | 0x0B..0x0C | 0x0E..0x7F | 0x80..0xFF)+;
>
> but I don't understand wht it is required to split the last range into
> two ranges.

Seems like ragel treats this as a signed char, i.e. -128..127. Your code 
appears to be a nice and portable workaround.

I've hit a "similar" problem recently -- the issue was a signedness of a 
char, but in a different context. I don't think it applies, but the patch 
is at [1] anyway.

Cheers,
Jan

[1] 
http://repo.or.cz/w/ragel-jkt.git/commitdiff/dc238e78cd3024889b6fb2618fe5bbc20179a132

-- 
Trojitá, a fast Qt IMAP e-mail client -- http://trojita.flaska.net/

_______________________________________________
ragel-users mailing list
ragel-users at complang.org
http://www.complang.org/mailman/listinfo/ragel-users


More information about the ragel-users mailing list