Fixed error in ruby code generation which crept in during the last change.
authorthurston <thurston@052ea7fc-9027-0410-9066-f65837a77df0>
Mon, 12 Feb 2007 03:51:30 +0000 (03:51 +0000)
committerthurston <thurston@052ea7fc-9027-0410-9066-f65837a77df0>
Mon, 12 Feb 2007 03:51:30 +0000 (03:51 +0000)
Updated the machine name and alphtype in atoi3 to reflect the fact that it is a
ruby test.

git-svn-id: http://svn.complang.org/ragel/trunk@102 052ea7fc-9027-0410-9066-f65837a77df0

rlgen-ruby/rubycodegen.cpp
test/atoi3.rl

index 75df018..5d34a1e 100644 (file)
@@ -1220,7 +1220,7 @@ std::ostream &RubyCodeGen::ACTIONS_ARRAY()
 {
        START_ARRAY_LINE();
        int totalActions = 0;
-       ARRAY_ITEM( 0, ++totalActions, false );
+       ARRAY_ITEM( INT(0), ++totalActions, false );
        for ( ActionTableMap::Iter act = redFsm->actionMap; act.lte(); act++ ) {
                /* Write out the length, which will never be the last character. */
                ARRAY_ITEM( INT(act->key.length()), ++totalActions, false );
index 4df39af..463f307 100644 (file)
@@ -7,8 +7,7 @@ neg = false
 val = 0
 
 %%{
-    machine atoi1_java;
-    alphtype byte;
+    machine atoi3;
     action begin {
         neg = false;
         val = 0;
@@ -42,7 +41,7 @@ def run_machine( data )
        %% write init;
        %% write exec;
        %% write eof;
-       if  cs >= atoi1_java_first_final
+       if  cs >= atoi3_first_final
                puts "ACCEPT"
        else
                puts "FAIL"