[ragel] C++ and ragel 7

Avi Kivity avi at scylladb.com
Thu Jun 1 16:57:59 UTC 2017


Testing out ragel 7 (7.0.0.9, from Fedora 26), I get these in my 
generated code:


         static const char _nfa_targs[] = {
             0, 0
         };

         static const char _nfa_offsets[] = {
             0, 0, 0, 0, 0, 0, 0, 0,
             0, 0, 0, 0, 0, 0, 0, 0,
             0, 0, 0, 0, 0, 0, 0, 0,
             0, 0, 0, 0, 0, 0, 0, 0,
             0, 0, 0, 0
         };

         static const char _nfa_push_actions[] = {
             0, 0
         };

         static const char _nfa_pop_trans[] = {
             0, 0
         };

Now, these are never used by the rest of the code, and also don't 
compile in some versions of the C++ compiler.


This is my command line:


     ragel -G2 -o $out $in


Is this a regression? Or am I doing something incorrectly?  Since those 
arrays are zeroed and unreferenced, I'm guessing they shouldn't have 
been emitted in the first place.





More information about the ragel-users mailing list