Generating java source code

Steve Horne stephenhorne... at
Wed Feb 14 15:55:23 UTC 2007

On Feb 13, 3:26 pm, Adrian Thurston <thurs... at> wrote:

> This
> issue has been fixed in trunk however. Ragel now generates the
> initialization functions directly, and splits them when they get big.

That seems a terrible way of initialising large arrays. You could
easily end up with more overhead (code to insert the items) than data,
depending on precisely how the VM bytecode works.

Couldn't the compiled data tables be stored in data files? I confess
I'm pretty ignorant of Java, beyond the basic language syntax, but
isn't there some way to embed application data files into those jar
files? Something intended to do a similar job to embedding resource
data into executables?

The file layout would have to be simple, though - there'd be no point
if you need another parser just to load it!

More information about the ragel-users mailing list