Ragel State Machine Compiler

6.6 GPL (GNU General Public License)    
3.2/5 19
Ragel State Machine Compiler compiles state machines from regular languages.





Ragel State Machine Compiler compiles finite state machines from regular languages into executable C/C /Objective-C code. Ragel state machines can not only recognize byte sequences as regular expression machines do, but can also execute code at arbitrary points in the recognition of a regular language.

Ragel can also be thought of as a finite state transducer compiler where output symbols represent blocks of code that get executed instead of written to the output stream.

When you wish to write down a regular language you start with some simple regular language and build a bigger one using the regular language operators union, concatenation, kleene star, intersection and subtraction.

This is precisely the way you describe to Ragel how to compile your finite state machines. Ragel also understands operators that embed actions into machines and operators that control any non-determinism in machines.

Ragel FSMs are closed under all of Ragel's regular language, action specification and priority assignment operators. This property allows arbitrary regular languages to be described. Complexity is limited only by available processing resources.

For example, you can make one machine that picks out specially formatted comments in C code, another machine that builds a list all function declarations and a third that identifies string constants then "or" them all together to make a single machine that performs all of these tasks concurrently and independently on one pass of the input.
Last updated on December 3rd, 2009
Ragel State Machine Compiler

0 User reviews so far.