Renaming to avoid name conflicts following the merge of the frontend and backend.
authorthurston <thurston@052ea7fc-9027-0410-9066-f65837a77df0>
Mon, 1 Sep 2008 16:45:30 +0000 (16:45 +0000)
committerthurston <thurston@052ea7fc-9027-0410-9066-f65837a77df0>
Mon, 1 Sep 2008 16:45:30 +0000 (16:45 +0000)
git-svn-id: http://svn.complang.org/ragel/trunk@466 052ea7fc-9027-0410-9066-f65837a77df0

43 files changed:
ragel/Makefile.in
ragel/main.cpp
redfsm/gendata.cpp
redfsm/gendata.h
redfsm/redfsm.cpp
redfsm/redfsm.h
redfsm/xmlparse.kh
redfsm/xmlparse.kl
redfsm/xmlscan.rl
rlgen-cd/fflatcodegen.cpp
rlgen-cd/fgotocodegen.cpp
rlgen-cd/flatcodegen.cpp
rlgen-cd/fsmcodegen.cpp
rlgen-cd/fsmcodegen.h
rlgen-cd/ftabcodegen.cpp
rlgen-cd/gotocodegen.cpp
rlgen-cd/gotocodegen.h
rlgen-cd/ipgotocodegen.cpp
rlgen-cd/splitcodegen.cpp
rlgen-cd/tabcodegen.cpp
rlgen-csharp/fflatcodegen.cpp
rlgen-csharp/fgotocodegen.cpp
rlgen-csharp/flatcodegen.cpp
rlgen-csharp/fsmcodegen.cpp
rlgen-csharp/fsmcodegen.h
rlgen-csharp/ftabcodegen.cpp
rlgen-csharp/gotocodegen.cpp
rlgen-csharp/gotocodegen.h
rlgen-csharp/ipgotocodegen.cpp
rlgen-csharp/splitcodegen.cpp
rlgen-csharp/tabcodegen.cpp
rlgen-dot/gvdotgen.cpp
rlgen-dot/main.cpp
rlgen-java/javacodegen.cpp
rlgen-java/javacodegen.h
rlgen-ruby/rbx-gotocodegen.cpp
rlgen-ruby/rbx-gotocodegen.h
rlgen-ruby/ruby-codegen.cpp
rlgen-ruby/ruby-codegen.h
rlgen-ruby/ruby-fflatcodegen.cpp
rlgen-ruby/ruby-flatcodegen.cpp
rlgen-ruby/ruby-ftabcodegen.cpp
rlgen-ruby/ruby-tabcodegen.cpp

index 5e54e57..6190a5f 100644 (file)
@@ -18,7 +18,7 @@
 #   along with Ragel; if not, write to the Free Software
 #   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA 
 
-INCS += -I../common -I../aapl
+INCS += -I../common -I../aapl -I../redfsm
 DEFS +=
 
 CFLAGS += -g -Wall
index 3121420..1e11cef 100644 (file)
@@ -54,6 +54,7 @@
 #include "vector.h"
 #include "version.h"
 #include "common.h"
+#include "xmlparse.h"
 
 using std::istream;
 using std::ostream;
index 8598aaa..c4c503b 100644 (file)
@@ -73,7 +73,7 @@ void CodeGenData::createMachine()
 
 void CodeGenData::initActionList( unsigned long length )
 { 
-       allActions = new Action[length];
+       allActions = new GenAction[length];
        for ( unsigned long a = 0; a < length; a++ )
                actionList.append( allActions+a );
 }
@@ -274,7 +274,7 @@ void CodeGenData::resolveTargetStates( GenInlineList *inlineList )
 
 void CodeGenData::closeMachine()
 {
-       for ( ActionList::Iter a = actionList; a.lte(); a++ )
+       for ( GenActionList::Iter a = actionList; a.lte(); a++ )
                resolveTargetStates( a->inlineList );
 
        /* Note that even if we want a complete graph we do not give the error
@@ -282,7 +282,7 @@ void CodeGenData::closeMachine()
         * loop when in the error state. */
 
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
-               for ( StateCondList::Iter sci = st->stateCondList; sci.lte(); sci++ )
+               for ( GenStateCondList::Iter sci = st->stateCondList; sci.lte(); sci++ )
                        st->stateCondVect.append( sci );
        }
 }
@@ -300,21 +300,21 @@ bool CodeGenData::setAlphType( char *data )
 
 void CodeGenData::initCondSpaceList( ulong length )
 {
-       allCondSpaces = new CondSpace[length];
+       allCondSpaces = new GenCondSpace[length];
        for ( ulong c = 0; c < length; c++ )
                condSpaceList.append( allCondSpaces + c );
 }
 
 void CodeGenData::newCondSpace( int cnum, int condSpaceId, Key baseKey )
 {
-       CondSpace *cond = allCondSpaces + cnum;
+       GenCondSpace *cond = allCondSpaces + cnum;
        cond->condSpaceId = condSpaceId;
        cond->baseKey = baseKey;
 }
 
 void CodeGenData::condSpaceItem( int cnum, long condActionId )
 {
-       CondSpace *cond = allCondSpaces + cnum;
+       GenCondSpace *cond = allCondSpaces + cnum;
        cond->condSet.append( allActions + condActionId );
 }
 
@@ -328,19 +328,19 @@ void CodeGenData::addStateCond( int snum, Key lowKey, Key highKey, long condNum
        RedStateAp *curState = allStates + snum;
 
        /* Create the new state condition. */
-       StateCond *stateCond = new StateCond;
+       GenStateCond *stateCond = new GenStateCond;
        stateCond->lowKey = lowKey;
        stateCond->highKey = highKey;
 
        /* Assign it a cond space. */
-       CondSpace *condSpace = allCondSpaces + condNum;
+       GenCondSpace *condSpace = allCondSpaces + condNum;
        stateCond->condSpace = condSpace;
 
        curState->stateCondList.append( stateCond );
 }
 
 
-CondSpace *CodeGenData::findCondSpace( Key lowKey, Key highKey )
+GenCondSpace *CodeGenData::findCondSpace( Key lowKey, Key highKey )
 {
        for ( CondSpaceList::Iter cs = condSpaceList; cs.lte(); cs++ ) {
                Key csHighKey = cs->baseKey;
@@ -386,7 +386,7 @@ void CodeGenData::findFinalActionRefs()
                for ( RedTransList::Iter rtel = st->outSingle; rtel.lte(); rtel++ ) {
                        if ( rtel->value->action != 0 ) {
                                rtel->value->action->numTransRefs += 1;
-                               for ( ActionTable::Iter item = rtel->value->action->key; item.lte(); item++ )
+                               for ( GenActionTable::Iter item = rtel->value->action->key; item.lte(); item++ )
                                        item->value->numTransRefs += 1;
                        }
                }
@@ -395,7 +395,7 @@ void CodeGenData::findFinalActionRefs()
                for ( RedTransList::Iter rtel = st->outRange; rtel.lte(); rtel++ ) {
                        if ( rtel->value->action != 0 ) {
                                rtel->value->action->numTransRefs += 1;
-                               for ( ActionTable::Iter item = rtel->value->action->key; item.lte(); item++ )
+                               for ( GenActionTable::Iter item = rtel->value->action->key; item.lte(); item++ )
                                        item->value->numTransRefs += 1;
                        }
                }
@@ -403,41 +403,41 @@ void CodeGenData::findFinalActionRefs()
                /* Reference count default transition. */
                if ( st->defTrans != 0 && st->defTrans->action != 0 ) {
                        st->defTrans->action->numTransRefs += 1;
-                       for ( ActionTable::Iter item = st->defTrans->action->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = st->defTrans->action->key; item.lte(); item++ )
                                item->value->numTransRefs += 1;
                }
 
                /* Reference count eof transitions. */
                if ( st->eofTrans != 0 && st->eofTrans->action != 0 ) {
                        st->eofTrans->action->numTransRefs += 1;
-                       for ( ActionTable::Iter item = st->eofTrans->action->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = st->eofTrans->action->key; item.lte(); item++ )
                                item->value->numTransRefs += 1;
                }
 
                /* Reference count to state actions. */
                if ( st->toStateAction != 0 ) {
                        st->toStateAction->numToStateRefs += 1;
-                       for ( ActionTable::Iter item = st->toStateAction->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = st->toStateAction->key; item.lte(); item++ )
                                item->value->numToStateRefs += 1;
                }
 
                /* Reference count from state actions. */
                if ( st->fromStateAction != 0 ) {
                        st->fromStateAction->numFromStateRefs += 1;
-                       for ( ActionTable::Iter item = st->fromStateAction->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = st->fromStateAction->key; item.lte(); item++ )
                                item->value->numFromStateRefs += 1;
                }
 
                /* Reference count EOF actions. */
                if ( st->eofAction != 0 ) {
                        st->eofAction->numEofRefs += 1;
-                       for ( ActionTable::Iter item = st->eofAction->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = st->eofAction->key; item.lte(); item++ )
                                item->value->numEofRefs += 1;
                }
        }
 }
 
-void CodeGenData::analyzeAction( Action *act, GenInlineList *inlineList )
+void CodeGenData::analyzeAction( GenAction *act, GenInlineList *inlineList )
 {
        for ( GenInlineList::Iter item = *inlineList; item.lte(); item++ ) {
                /* Only consider actions that are referenced. */
@@ -500,7 +500,7 @@ void CodeGenData::analyzeActionList( RedAction *redAct, GenInlineList *inlineLis
 void CodeGenData::assignActionIds()
 {
        int nextActionId = 0;
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Only ever interested in referenced actions. */
                if ( act->numRefs() > 0 )
                        act->actionId = nextActionId++;
@@ -597,7 +597,7 @@ void CodeGenData::setValueLimits()
                /* Maximum values going into the action array. */
                if ( at->key.length() > redFsm->maxActArrItem )
                        redFsm->maxActArrItem = at->key.length();
-               for ( ActionTable::Iter item = at->key; item.lte(); item++ ) {
+               for ( GenActionTable::Iter item = at->key; item.lte(); item++ ) {
                        if ( item->value->actionId > redFsm->maxActArrItem )
                                redFsm->maxActArrItem = item->value->actionId;
                }
@@ -613,7 +613,7 @@ void CodeGenData::analyzeMachine()
        findFinalActionRefs();
 
        /* Check if there are any calls in action code. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Record the occurrence of various kinds of actions. */
                if ( act->numToStateRefs > 0 )
                        redFsm->bAnyToStateActions = true;
@@ -630,7 +630,7 @@ void CodeGenData::analyzeMachine()
 
        /* Analyze reduced action lists. */
        for ( ActionTableMap::Iter redAct = redFsm->actionMap; redAct.lte(); redAct++ ) {
-               for ( ActionTable::Iter act = redAct->key; act.lte(); act++ )
+               for ( GenActionTable::Iter act = redAct->key; act.lte(); act++ )
                        analyzeActionList( redAct, act->value->inlineList );
        }
 
index b9ab577..f8c6d2f 100644 (file)
@@ -32,7 +32,7 @@ using std::ostream;
 extern bool generateDot;
 
 struct NameInst;
-typedef DList<Action> ActionList;
+typedef DList<GenAction> GenActionList;
 
 typedef unsigned long ulong;
 
@@ -105,15 +105,15 @@ struct CodeGenData
        char *fsmName;
        ostream &out;
        RedFsmAp *redFsm;
-       Action *allActions;
+       GenAction *allActions;
        RedAction *allActionTables;
        Condition *allConditions;
-       CondSpace *allCondSpaces;
+       GenCondSpace *allCondSpaces;
        RedStateAp *allStates;
        NameInst **nameIndex;
        int startState;
        int errState;
-       ActionList actionList;
+       GenActionList actionList;
        ConditionList conditionList;
        CondSpaceList condSpaceList;
        GenInlineList *getKeyExpr;
@@ -175,7 +175,7 @@ struct CodeGenData
        void initStateCondList( int snum, ulong length );
        void addStateCond( int snum, Key lowKey, Key highKey, long condNum );
 
-       CondSpace *findCondSpace( Key lowKey, Key highKey );
+       GenCondSpace *findCondSpace( Key lowKey, Key highKey );
        Condition *findCondition( Key key );
 
        bool setAlphType( char *data );
@@ -185,7 +185,7 @@ struct CodeGenData
 
        /* Gather various info on the machine. */
        void analyzeActionList( RedAction *redAct, GenInlineList *inlineList );
-       void analyzeAction( Action *act, GenInlineList *inlineList );
+       void analyzeAction( GenAction *act, GenInlineList *inlineList );
        void findFinalActionRefs();
        void analyzeMachine();
 
index 72f7660..e02493e 100644 (file)
@@ -29,7 +29,7 @@ using std::ostringstream;
 
 /* KeyOps *keyOps = 0; */
 
-string Action::nameOrLoc()
+string GenAction::nameOrLoc()
 {
        if ( name != 0 )
                return string(name);
@@ -298,10 +298,10 @@ void RedFsmAp::makeFlat()
                        st->condHighKey = st->stateCondList.tail->highKey;
 
                        unsigned long long span = keyOps->span( st->condLowKey, st->condHighKey );
-                       st->condList = new CondSpace*[ span ];
-                       memset( st->condList, 0, sizeof(CondSpace*)*span );
+                       st->condList = new GenCondSpace*[ span ];
+                       memset( st->condList, 0, sizeof(GenCondSpace*)*span );
 
-                       for ( StateCondList::Iter sci = st->stateCondList; sci.lte(); sci++ ) {
+                       for ( GenStateCondList::Iter sci = st->stateCondList; sci.lte(); sci++ ) {
                                unsigned long long base, trSpan;
                                base = keyOps->span( st->condLowKey, sci->lowKey )-1;
                                trSpan = keyOps->span( sci->lowKey, sci->highKey );
index eb8d4d9..c53352a 100644 (file)
@@ -48,7 +48,7 @@ using std::string;
 
 struct RedStateAp;
 struct GenInlineList;
-struct Action;
+struct GenAction;
 
 /* Location in an input file. */
 struct GenInputLoc
@@ -92,11 +92,11 @@ struct GenInlineItem
 struct GenInlineList : public DList<GenInlineItem> { };
 
 /* Element in list of actions. Contains the string for the code to exectute. */
-struct Action 
+struct GenAction 
 :
-       public DListEl<Action>
+       public DListEl<GenAction>
 {
-       Action( )
+       GenAction( )
        :
                name(0),
                inlineList(0), 
@@ -130,23 +130,23 @@ struct Action
 struct RedStateAp;
 struct StateAp;
 
-/* Transistion Action Element. */
-typedef SBstMapEl< int, Action* > ActionTableEl;
+/* Transistion GenAction Element. */
+typedef SBstMapEl< int, GenAction* > GenActionTableEl;
 
-/* Transition Action Table.  */
-struct ActionTable 
-       : public SBstMap< int, Action*, CmpOrd<int> >
+/* Transition GenAction Table.  */
+struct GenActionTable 
+       : public SBstMap< int, GenAction*, CmpOrd<int> >
 {
-       void setAction( int ordering, Action *action );
-       void setActions( int *orderings, Action **actions, int nActs );
-       void setActions( const ActionTable &other );
+       void setAction( int ordering, GenAction *action );
+       void setActions( int *orderings, GenAction **actions, int nActs );
+       void setActions( const GenActionTable &other );
 };
 
 /* Compare of a whole action table element (key & value). */
-struct CmpActionTableEl
+struct CmpGenActionTableEl
 {
-       static int compare( const ActionTableEl &action1, 
-                       const ActionTableEl &action2 )
+       static int compare( const GenActionTableEl &action1, 
+                       const GenActionTableEl &action2 )
        {
                if ( action1.key < action2.key )
                        return -1;
@@ -160,8 +160,8 @@ struct CmpActionTableEl
        }
 };
 
-/* Compare for ActionTable. */
-typedef CmpSTable< ActionTableEl, CmpActionTableEl > CmpActionTable;
+/* Compare for GenActionTable. */
+typedef CmpSTable< GenActionTableEl, CmpGenActionTableEl > CmpGenActionTable;
 
 /* Set of states. */
 typedef BstSet<RedStateAp*> RedStateSet;
@@ -185,10 +185,10 @@ struct RedAction
                bAnyBreakStmt(false)
        { }
        
-       const ActionTable &getKey() 
+       const GenActionTable &getKey() 
                { return key; }
 
-       ActionTable key;
+       GenActionTable key;
        int actListId;
        int location;
        IntSet *eofRefs;
@@ -209,7 +209,7 @@ struct RedAction
        bool bAnyCurStateRef;
        bool bAnyBreakStmt;
 };
-typedef AvlTree<RedAction, ActionTable, CmpActionTable> ActionTableMap;
+typedef AvlTree<RedAction, GenActionTable, CmpGenActionTable> ActionTableMap;
 
 /* Reduced transition. */
 struct RedTransAp
@@ -287,7 +287,7 @@ typedef MergeSort<RedSpanMapEl, CmpRedSpanMapEl> RedSpanMapSort;
 typedef Vector<int> EntryIdVect;
 typedef Vector<char*> EntryNameVect;
 
-typedef Vector< Action* > CondSet;
+typedef Vector< GenAction* > GenCondSet;
 
 struct Condition
 {
@@ -296,33 +296,33 @@ struct Condition
 
        Key key;
        Key baseKey;
-       CondSet condSet;
+       GenCondSet condSet;
 
        Condition *next, *prev;
 };
 typedef DList<Condition> ConditionList;
 
-struct CondSpace
+struct GenCondSpace
 {
        Key baseKey;
-       CondSet condSet;
+       GenCondSet condSet;
        int condSpaceId;
 
-       CondSpace *next, *prev;
+       GenCondSpace *next, *prev;
 };
-typedef DList<CondSpace> CondSpaceList;
+typedef DList<GenCondSpace> CondSpaceList;
 
-struct StateCond
+struct GenStateCond
 {
        Key lowKey;
        Key highKey;
 
-       CondSpace *condSpace;
+       GenCondSpace *condSpace;
 
-       StateCond *prev, *next;
+       GenStateCond *prev, *next;
 };
-typedef DList<StateCond> StateCondList;
-typedef Vector<StateCond*> StateCondVect;
+typedef DList<GenStateCond> GenStateCondList;
+typedef Vector<GenStateCond*> StateCondVect;
 
 /* Reduced state. */
 struct RedStateAp
@@ -354,7 +354,7 @@ struct RedStateAp
 
        /* For flat conditions. */
        Key condLowKey, condHighKey;
-       CondSpace **condList;
+       GenCondSpace **condList;
 
        /* For flat keys. */
        Key lowKey, highKey;
@@ -372,7 +372,7 @@ struct RedStateAp
        RedAction *eofAction;
        RedTransAp *eofTrans;
        int id;
-       StateCondList stateCondList;
+       GenStateCondList stateCondList;
        StateCondVect stateCondVect;
 
        /* Pointers for the list of states. */
index 431e329..8a5aff5 100644 (file)
 
 #include "vector.h"
 #include "gendata.h"
+#include "buffer.h"
 #include <iostream>
 
+using std::istream;
 using std::ostream;
 
+#define XML_BUFSIZE 4096
+
 struct AttrMarker
 {
        char *id;
@@ -81,11 +85,7 @@ struct XMLTagHashPair
     int id;
 };
 
-struct Token
-{
-       XMLTag *tag;
-       GenInputLoc loc;
-};
+struct Token;
 
 struct GenInlineItem;
 struct GenInlineList;
@@ -93,6 +93,37 @@ struct GenInlineList;
 struct LmSwitchVect;
 struct LmSwitchAction;
 
+struct XmlScanner
+{
+       XmlScanner( const char *fileName, istream &input );
+
+       int scan();
+       void adjustAttrPointers( int distance );
+       std::ostream &error();
+
+       const char *fileName;
+       istream &input;
+
+       /* Scanner State. */
+       int cs, act, have, curline, curcol;
+       char *ts, *te;
+       char *p, *pe;
+       int done;
+
+       /* Token data */
+       char *data;
+       int data_len;
+       int value;
+       AttrMkList attrMkList;
+       Buffer buffer;
+       char *tag_id_start;
+       int tag_id_len;
+       int token_col, token_line;
+
+       char buf[XML_BUFSIZE];
+};
+
+
 struct XmlParser
 {
        %%{
index 967f6ef..e725fcc 100644 (file)
@@ -36,6 +36,12 @@ Key readKey( char *td, char **end );
 long readOffsetPtr( char *td, char **end );
 unsigned long readLength( char *td );
 
+struct Token
+{
+       XMLTag *tag;
+       GenInputLoc loc;
+};
+
 CodeGenData *makeCodeGen( char *sourceFileName, char *fsmName, 
                ostream &out, bool wantComplete )
 {
index 0835699..23dcaca 100644 (file)
 #include <string.h>
 #include "vector.h"
 #include "xmlparse.h"
-#include "buffer.h"
 
 using std::istream;
 using std::cout;
 using std::cerr;
 using std::endl;
 
-#define BUFSIZE 4096
-
 %%{
        machine XmlScanner;
        write data;
@@ -45,50 +42,21 @@ public:
        static struct XMLTagHashPair *in_word_set (const char *str, unsigned int len);
 };
 
-struct XmlScanner
+XmlScanner::XmlScanner( const char *fileName, istream &input ) : 
+       fileName(fileName),
+       input(input), 
+       curline(1), 
+       curcol(1),
+       p(0), pe(0), 
+       done(false),
+       data(0), data_len(0),
+       value(0)
 {
-       XmlScanner( const char *fileName, istream &input ) : 
-               fileName(fileName),
-               input(input), 
-               curline(1), 
-               curcol(1),
-               p(0), pe(0), 
-               done(false),
-               data(0), data_len(0),
-               value(0)
-       {
-               %%{
-                       machine XmlScanner;
-                       write init;
-               }%%
-       }
-       
-       int scan();
-       void adjustAttrPointers( int distance );
-       std::ostream &error();
-
-       const char *fileName;
-       istream &input;
-
-       /* Scanner State. */
-       int cs, act, have, curline, curcol;
-       char *ts, *te;
-       char *p, *pe;
-       int done;
-
-       /* Token data */
-       char *data;
-       int data_len;
-       int value;
-       AttrMkList attrMkList;
-       Buffer buffer;
-       char *tag_id_start;
-       int tag_id_len;
-       int token_col, token_line;
-
-       char buf[BUFSIZE];
-};
-
+       %%{
+               machine XmlScanner;
+               write init;
+       }%%
+}
 
 #define TK_NO_TOKEN (-1)
 #define TK_ERR 1
@@ -211,7 +179,7 @@ int XmlScanner::scan( )
                        }
 
                        p = buf + have;
-                       space = BUFSIZE - have;
+                       space = XML_BUFSIZE - have;
 
                        if ( space == 0 ) {
                                /* We filled up the buffer trying to scan a token. */
index 56e6685..c76677f 100644 (file)
@@ -74,7 +74,7 @@ std::ostream &FFlatCodeGen::TO_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tbreak;\n";
@@ -96,7 +96,7 @@ std::ostream &FFlatCodeGen::FROM_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tbreak;\n";
@@ -116,7 +116,7 @@ std::ostream &FFlatCodeGen::EOF_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, true, false );
 
                        out << "\tbreak;\n";
@@ -138,7 +138,7 @@ std::ostream &FFlatCodeGen::ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tbreak;\n";
index 0a353f3..3988868 100644 (file)
@@ -36,7 +36,7 @@ std::ostream &FGotoCodeGen::EXEC_ACTIONS()
                        out << "f" << redAct->actListId << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tgoto _again;\n";
@@ -56,7 +56,7 @@ std::ostream &FGotoCodeGen::TO_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tbreak;\n";
@@ -78,7 +78,7 @@ std::ostream &FGotoCodeGen::FROM_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tbreak;\n";
@@ -98,7 +98,7 @@ std::ostream &FGotoCodeGen::EOF_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, true, false );
 
                        out << "\tbreak;\n";
index b9cdfca..66dc07b 100644 (file)
@@ -66,7 +66,7 @@ std::ostream &FlatCodeGen::TRANS_ACTION( RedTransAp *trans )
 std::ostream &FlatCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -83,7 +83,7 @@ std::ostream &FlatCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &FlatCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -100,7 +100,7 @@ std::ostream &FlatCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &FlatCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -118,7 +118,7 @@ std::ostream &FlatCodeGen::EOF_ACTION_SWITCH()
 std::ostream &FlatCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -651,13 +651,13 @@ void FlatCodeGen::COND_TRANSLATE()
        out <<
                "       switch ( _cond ) {\n";
        for ( CondSpaceList::Iter csi = condSpaceList; csi.lte(); csi++ ) {
-               CondSpace *condSpace = csi;
+               GenCondSpace *condSpace = csi;
                out << "        case " << condSpace->condSpaceId + 1 << ": {\n";
                out << TABS(2) << "_widec = " << CAST(WIDE_ALPH_TYPE()) << "(" <<
                                KEY(condSpace->baseKey) << " + (" << GET_KEY() << 
                                " - " << KEY(keyOps->minKey) << "));\n";
 
-               for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+               for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                        out << TABS(2) << "if ( ";
                        CONDITION( out, *csi );
                        Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
index ab8f4ad..942769c 100644 (file)
@@ -121,7 +121,7 @@ std::ostream &FsmCodeGen::ACTIONS_ARRAY()
                if ( totalActions++ % 8 == 7 )
                        out << "\n\t";
 
-               for ( ActionTable::Iter item = act->key; item.lte(); item++ ) {
+               for ( GenActionTable::Iter item = act->key; item.lte(); item++ ) {
                        out << item->value->actionId;
                        if ( ! (act.last() && item.last()) )
                                out << ", ";
@@ -500,7 +500,7 @@ string FsmCodeGen::LDIR_PATH( char *path )
        return ret.str();
 }
 
-void FsmCodeGen::ACTION( ostream &ret, Action *action, int targState, 
+void FsmCodeGen::ACTION( ostream &ret, GenAction *action, int targState, 
                bool inFinish, bool csForced )
 {
        /* Write the preprocessor line info for going into the source file. */
@@ -512,7 +512,7 @@ void FsmCodeGen::ACTION( ostream &ret, Action *action, int targState,
        ret << "}\n";
 }
 
-void FsmCodeGen::CONDITION( ostream &ret, Action *condition )
+void FsmCodeGen::CONDITION( ostream &ret, GenAction *condition )
 {
        ret << "\n";
        cdLineDirective( ret, sourceFileName, condition->loc.line );
index 5fa9bfb..6e75772 100644 (file)
@@ -40,7 +40,7 @@ using std::ostream;
 struct RedFsmAp;
 struct RedStateAp;
 struct CodeGenData;
-struct Action;
+struct GenAction;
 struct NameInst;
 struct GenInlineItem;
 struct GenInlineList;
@@ -76,9 +76,9 @@ protected:
        string TABS( int level );
        string KEY( Key key );
        string LDIR_PATH( char *path );
-       void ACTION( ostream &ret, Action *action, int targState, 
+       void ACTION( ostream &ret, GenAction *action, int targState, 
                        bool inFinish, bool csForced );
-       void CONDITION( ostream &ret, Action *condition );
+       void CONDITION( ostream &ret, GenAction *condition );
        string ALPH_TYPE();
        string WIDE_ALPH_TYPE();
        string ARRAY_TYPE( unsigned long maxVal );
index 3aac8af..6118b78 100644 (file)
@@ -103,7 +103,7 @@ std::ostream &FTabCodeGen::TO_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tbreak;\n";
@@ -125,7 +125,7 @@ std::ostream &FTabCodeGen::FROM_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tbreak;\n";
@@ -145,7 +145,7 @@ std::ostream &FTabCodeGen::EOF_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, true, false );
 
                        out << "\tbreak;\n";
@@ -167,7 +167,7 @@ std::ostream &FTabCodeGen::ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false, false );
 
                        out << "\tbreak;\n";
index 0309f76..e4999f0 100644 (file)
@@ -37,7 +37,7 @@ std::ostream &GotoCodeGen::TRANS_GOTO( RedTransAp *trans, int level )
 std::ostream &GotoCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -54,7 +54,7 @@ std::ostream &GotoCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &GotoCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -71,7 +71,7 @@ std::ostream &GotoCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &GotoCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -88,7 +88,7 @@ std::ostream &GotoCodeGen::EOF_ACTION_SWITCH()
 std::ostream &GotoCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -237,14 +237,14 @@ void GotoCodeGen::STATE_GOTO_ERROR()
        out << "        goto _out;\n";
 }
 
-void GotoCodeGen::COND_TRANSLATE( StateCond *stateCond, int level )
+void GotoCodeGen::COND_TRANSLATE( GenStateCond *stateCond, int level )
 {
-       CondSpace *condSpace = stateCond->condSpace;
+       GenCondSpace *condSpace = stateCond->condSpace;
        out << TABS(level) << "_widec = " << CAST(WIDE_ALPH_TYPE()) << "(" <<
                        KEY(condSpace->baseKey) << " + (" << GET_KEY() << 
                        " - " << KEY(keyOps->minKey) << "));\n";
 
-       for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+       for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                out << TABS(level) << "if ( ";
                CONDITION( out, *csi );
                Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
@@ -256,7 +256,7 @@ void GotoCodeGen::emitCondBSearch( RedStateAp *state, int level, int low, int hi
 {
        /* Get the mid position, staying on the lower end of the range. */
        int mid = (low + high) >> 1;
-       StateCond **data = state->stateCondVect.data;
+       GenStateCond **data = state->stateCondVect.data;
 
        /* Determine if we need to look higher or lower. */
        bool anyLower = mid > low;
index dace568..7de21f1 100644 (file)
@@ -32,7 +32,7 @@ struct CodeGenData;
 struct NameInst;
 struct RedTransAp;
 struct RedStateAp;
-struct StateCond;
+struct GenStateCond;
 
 /*
  * Goto driven fsm.
@@ -69,7 +69,7 @@ public:
        std::ostream &FROM_STATE_ACTIONS();
        std::ostream &EOF_ACTIONS();
 
-       void COND_TRANSLATE( StateCond *stateCond, int level );
+       void COND_TRANSLATE( GenStateCond *stateCond, int level );
        void emitCondBSearch( RedStateAp *state, int level, int low, int high );
        void STATE_CONDS( RedStateAp *state, bool genDefault ); 
 
index 220df53..9d10d9f 100644 (file)
@@ -140,7 +140,7 @@ bool IpGotoCodeGen::IN_TRANS_ACTIONS( RedStateAp *state )
                                out << "        " << CS() << " = " << trans->targ->id << ";\n";
 
                        /* Write each action in the list. */
-                       for ( ActionTable::Iter item = trans->action->key; item.lte(); item++ ) {
+                       for ( GenActionTable::Iter item = trans->action->key; item.lte(); item++ ) {
                                ACTION( out, item->value, trans->targ->id, false, 
                                                trans->action->anyNextStmt() );
                        }
@@ -169,7 +169,7 @@ void IpGotoCodeGen::GOTO_HEADER( RedStateAp *state )
        if ( state->toStateAction != 0 ) {
                /* Remember that we wrote an action. Write every action in the list. */
                anyWritten = true;
-               for ( ActionTable::Iter item = state->toStateAction->key; item.lte(); item++ ) {
+               for ( GenActionTable::Iter item = state->toStateAction->key; item.lte(); item++ ) {
                        ACTION( out, item->value, state->id, false, 
                                        state->toStateAction->anyNextStmt() );
                }
@@ -194,7 +194,7 @@ void IpGotoCodeGen::GOTO_HEADER( RedStateAp *state )
        if ( state->fromStateAction != 0 ) {
                /* Remember that we wrote an action. Write every action in the list. */
                anyWritten = true;
-               for ( ActionTable::Iter item = state->fromStateAction->key; item.lte(); item++ ) {
+               for ( GenActionTable::Iter item = state->fromStateAction->key; item.lte(); item++ ) {
                        ACTION( out, item->value, state->id, false,
                                        state->fromStateAction->anyNextStmt() );
                }
@@ -291,7 +291,7 @@ std::ostream &IpGotoCodeGen::FINISH_CASES()
                        anyWritten = true;
 
                        /* Write each action in the eof action list. */
-                       for ( ActionTable::Iter item = act->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = act->key; item.lte(); item++ )
                                ACTION( out, item->value, STATE_ERR_STATE, true, false );
                        out << "\tbreak;\n";
                }
@@ -344,7 +344,7 @@ void IpGotoCodeGen::setLabelsNeeded()
                         * invoked on characters (ie, not from out action code). */
                        if ( trans->action != 0 ) {
                                /* Loop the actions. */
-                               for ( ActionTable::Iter act = trans->action->key; act.lte(); act++ ) {
+                               for ( GenActionTable::Iter act = trans->action->key; act.lte(); act++ ) {
                                        /* Get the action and walk it's tree. */
                                        setLabelsNeeded( act->value->inlineList );
                                }
index d4fc07d..5faf602 100644 (file)
@@ -68,7 +68,7 @@ void SplitCodeGen::GOTO_HEADER( RedStateAp *state, bool stateInPartition )
        if ( state->toStateAction != 0 ) {
                /* Remember that we wrote an action. Write every action in the list. */
                anyWritten = true;
-               for ( ActionTable::Iter item = state->toStateAction->key; item.lte(); item++ ) {
+               for ( GenActionTable::Iter item = state->toStateAction->key; item.lte(); item++ ) {
                        ACTION( out, item->value, state->id, false,
                                        state->toStateAction->anyNextStmt() );
                }
@@ -93,7 +93,7 @@ void SplitCodeGen::GOTO_HEADER( RedStateAp *state, bool stateInPartition )
        if ( state->fromStateAction != 0 ) {
                /* Remember that we wrote an action. Write every action in the list. */
                anyWritten = true;
-               for ( ActionTable::Iter item = state->fromStateAction->key; item.lte(); item++ ) {
+               for ( GenActionTable::Iter item = state->fromStateAction->key; item.lte(); item++ ) {
                        ACTION( out, item->value, state->id, false,
                                        state->fromStateAction->anyNextStmt() );
                }
@@ -158,7 +158,7 @@ std::ostream &SplitCodeGen::PART_TRANS( int partition )
                                        out << "        " << CS() << " = " << trans->targ->id << ";\n";
 
                                /* Write each action in the list. */
-                               for ( ActionTable::Iter item = trans->action->key; item.lte(); item++ ) {
+                               for ( GenActionTable::Iter item = trans->action->key; item.lte(); item++ ) {
                                        ACTION( out, item->value, trans->targ->id, false,
                                                        trans->action->anyNextStmt() );
                                }
@@ -178,7 +178,7 @@ std::ostream &SplitCodeGen::PART_TRANS( int partition )
 
                        if ( st->toStateAction != 0 ) {
                                /* Remember that we wrote an action. Write every action in the list. */
-                               for ( ActionTable::Iter item = st->toStateAction->key; item.lte(); item++ ) {
+                               for ( GenActionTable::Iter item = st->toStateAction->key; item.lte(); item++ ) {
                                        ACTION( out, item->value, st->id, false,
                                                        st->toStateAction->anyNextStmt() );
                                }
@@ -471,7 +471,7 @@ void SplitCodeGen::setLabelsNeeded( RedStateAp *fromState, RedTransAp *trans )
         * invoked on characters (ie, not from out action code). */
        if ( trans->action != 0 ) {
                /* Loop the actions. */
-               for ( ActionTable::Iter act = trans->action->key; act.lte(); act++ ) {
+               for ( GenActionTable::Iter act = trans->action->key; act.lte(); act++ ) {
                        /* Get the action and walk it's tree. */
                        setLabelsNeeded( fromState, act->value->inlineList );
                }
index a46e997..82d9d43 100644 (file)
@@ -95,7 +95,7 @@ std::ostream &TabCodeGen::TRANS_ACTION( RedTransAp *trans )
 std::ostream &TabCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -112,7 +112,7 @@ std::ostream &TabCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &TabCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -129,7 +129,7 @@ std::ostream &TabCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &TabCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -147,7 +147,7 @@ std::ostream &TabCodeGen::EOF_ACTION_SWITCH()
 std::ostream &TabCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -357,7 +357,7 @@ std::ostream &TabCodeGen::COND_KEYS()
        int totalTrans = 0;
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
                /* Loop the state's transitions. */
-               for ( StateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
+               for ( GenStateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
                        /* Lower key. */
                        out << KEY( sc->lowKey ) << ", ";
                        if ( ++totalTrans % IALL == 0 )
@@ -382,7 +382,7 @@ std::ostream &TabCodeGen::COND_SPACES()
        int totalTrans = 0;
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
                /* Loop the state's transitions. */
-               for ( StateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
+               for ( GenStateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
                        /* Cond Space id. */
                        out << sc->condSpace->condSpaceId << ", ";
                        if ( ++totalTrans % IALL == 0 )
@@ -893,13 +893,13 @@ void TabCodeGen::COND_TRANSLATE()
                                                        " + ((_mid - _keys)>>1)] ) {\n";
 
        for ( CondSpaceList::Iter csi = condSpaceList; csi.lte(); csi++ ) {
-               CondSpace *condSpace = csi;
+               GenCondSpace *condSpace = csi;
                out << "        case " << condSpace->condSpaceId << ": {\n";
                out << TABS(2) << "_widec = " << CAST(WIDE_ALPH_TYPE()) << "(" <<
                                KEY(condSpace->baseKey) << " + (" << GET_KEY() << 
                                " - " << KEY(keyOps->minKey) << "));\n";
 
-               for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+               for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                        out << TABS(2) << "if ( ";
                        CONDITION( out, *csi );
                        Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
index cbce95f..fbccbcd 100644 (file)
@@ -74,7 +74,7 @@ std::ostream &CSharpFFlatCodeGen::TO_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tbreak;\n";
@@ -96,7 +96,7 @@ std::ostream &CSharpFFlatCodeGen::FROM_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tbreak;\n";
@@ -116,7 +116,7 @@ std::ostream &CSharpFFlatCodeGen::EOF_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, true );
 
                        out << "\tbreak;\n";
@@ -138,7 +138,7 @@ std::ostream &CSharpFFlatCodeGen::ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tbreak;\n";
index c62ce14..a39289f 100644 (file)
@@ -36,7 +36,7 @@ std::ostream &CSharpFGotoCodeGen::EXEC_ACTIONS()
                        out << "f" << redAct->actListId << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tgoto _again;\n";
@@ -56,7 +56,7 @@ std::ostream &CSharpFGotoCodeGen::TO_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tbreak;\n";
@@ -78,7 +78,7 @@ std::ostream &CSharpFGotoCodeGen::FROM_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tbreak;\n";
@@ -98,7 +98,7 @@ std::ostream &CSharpFGotoCodeGen::EOF_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, true );
 
                        out << "\tbreak;\n";
index bb25d17..10f9f36 100644 (file)
@@ -66,7 +66,7 @@ std::ostream &CSharpFlatCodeGen::TRANS_ACTION( RedTransAp *trans )
 std::ostream &CSharpFlatCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -83,7 +83,7 @@ std::ostream &CSharpFlatCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &CSharpFlatCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -100,7 +100,7 @@ std::ostream &CSharpFlatCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &CSharpFlatCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -118,7 +118,7 @@ std::ostream &CSharpFlatCodeGen::EOF_ACTION_SWITCH()
 std::ostream &CSharpFlatCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -668,13 +668,13 @@ void CSharpFlatCodeGen::COND_TRANSLATE()
        out <<
                "       switch ( _cond ) {\n";
        for ( CondSpaceList::Iter csi = condSpaceList; csi.lte(); csi++ ) {
-               CondSpace *condSpace = csi;
+               GenCondSpace *condSpace = csi;
                out << "        case " << condSpace->condSpaceId + 1 << ": {\n";
                out << TABS(2) << "_widec = " << CAST(WIDE_ALPH_TYPE()) << "(" <<
                                KEY(condSpace->baseKey) << " + (" << GET_KEY() << 
                                " - " << KEY(keyOps->minKey) << "));\n";
 
-               for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+               for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                        out << TABS(2) << "if ( ";
                        CONDITION( out, *csi );
                        Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
index 2dc8a2d..fd46865 100644 (file)
@@ -130,7 +130,7 @@ std::ostream &CSharpFsmCodeGen::ACTIONS_ARRAY()
                if ( totalActions++ % 8 == 7 )
                        out << "\n\t";
 
-               for ( ActionTable::Iter item = act->key; item.lte(); item++ ) {
+               for ( GenActionTable::Iter item = act->key; item.lte(); item++ ) {
                        out << item->value->actionId;
                        if ( ! (act.last() && item.last()) )
                                out << ", ";
@@ -516,7 +516,7 @@ string CSharpFsmCodeGen::LDIR_PATH( char *path )
        return ret.str();
 }
 
-void CSharpFsmCodeGen::ACTION( ostream &ret, Action *action, int targState, bool inFinish )
+void CSharpFsmCodeGen::ACTION( ostream &ret, GenAction *action, int targState, bool inFinish )
 {
        /* Write the preprocessor line info for going into the source file. */
        csharpLineDirective( ret, sourceFileName, action->loc.line );
@@ -527,7 +527,7 @@ void CSharpFsmCodeGen::ACTION( ostream &ret, Action *action, int targState, bool
        ret << "}\n";
 }
 
-void CSharpFsmCodeGen::CONDITION( ostream &ret, Action *condition )
+void CSharpFsmCodeGen::CONDITION( ostream &ret, GenAction *condition )
 {
        ret << "\n";
        csharpLineDirective( ret, sourceFileName, condition->loc.line );
index ab85679..0bd7e48 100644 (file)
@@ -40,7 +40,7 @@ using std::ostream;
 struct RedFsmAp;
 struct RedStateAp;
 struct CodeGenData;
-struct Action;
+struct GenAction;
 struct NameInst;
 struct GenInlineItem;
 struct GenInlineList;
@@ -77,8 +77,8 @@ protected:
        string KEY( Key key );
        string ALPHA_KEY( Key key );
        string LDIR_PATH( char *path );
-       void ACTION( ostream &ret, Action *action, int targState, bool inFinish );
-       void CONDITION( ostream &ret, Action *condition );
+       void ACTION( ostream &ret, GenAction *action, int targState, bool inFinish );
+       void CONDITION( ostream &ret, GenAction *condition );
        string ALPH_TYPE();
        string WIDE_ALPH_TYPE();
        string ARRAY_TYPE( unsigned long maxVal );
index 421ee9b..4804a2d 100644 (file)
@@ -103,7 +103,7 @@ std::ostream &CSharpFTabCodeGen::TO_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tbreak;\n";
@@ -125,7 +125,7 @@ std::ostream &CSharpFTabCodeGen::FROM_STATE_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tbreak;\n";
@@ -145,7 +145,7 @@ std::ostream &CSharpFTabCodeGen::EOF_ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, true );
 
                        out << "\tbreak;\n";
@@ -167,7 +167,7 @@ std::ostream &CSharpFTabCodeGen::ACTION_SWITCH()
                        out << "\tcase " << redAct->actListId+1 << ":\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                        out << "\tbreak;\n";
index 0875aad..5172968 100644 (file)
@@ -37,7 +37,7 @@ std::ostream &CSharpGotoCodeGen::TRANS_GOTO( RedTransAp *trans, int level )
 std::ostream &CSharpGotoCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -54,7 +54,7 @@ std::ostream &CSharpGotoCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &CSharpGotoCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -71,7 +71,7 @@ std::ostream &CSharpGotoCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &CSharpGotoCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -88,7 +88,7 @@ std::ostream &CSharpGotoCodeGen::EOF_ACTION_SWITCH()
 std::ostream &CSharpGotoCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -237,14 +237,14 @@ void CSharpGotoCodeGen::STATE_GOTO_ERROR()
        out << "        goto _out;\n";
 }
 
-void CSharpGotoCodeGen::COND_TRANSLATE( StateCond *stateCond, int level )
+void CSharpGotoCodeGen::COND_TRANSLATE( GenStateCond *stateCond, int level )
 {
-       CondSpace *condSpace = stateCond->condSpace;
+       GenCondSpace *condSpace = stateCond->condSpace;
        out << TABS(level) << "_widec = " << CAST(WIDE_ALPH_TYPE()) << "(" <<
                        KEY(condSpace->baseKey) << " + (" << GET_KEY() << 
                        " - " << KEY(keyOps->minKey) << "));\n";
 
-       for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+       for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                out << TABS(level) << "if ( ";
                CONDITION( out, *csi );
                Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
@@ -256,7 +256,7 @@ void CSharpGotoCodeGen::emitCondBSearch( RedStateAp *state, int level, int low,
 {
        /* Get the mid position, staying on the lower end of the range. */
        int mid = (low + high) >> 1;
-       StateCond **data = state->stateCondVect.data;
+       GenStateCond **data = state->stateCondVect.data;
 
        /* Determine if we need to look higher or lower. */
        bool anyLower = mid > low;
index 565627e..2839d0e 100644 (file)
@@ -32,7 +32,7 @@ struct CodeGenData;
 struct NameInst;
 struct RedTransAp;
 struct RedStateAp;
-struct StateCond;
+struct GenStateCond;
 
 /*
  * Goto driven fsm.
@@ -69,7 +69,7 @@ public:
        std::ostream &FROM_STATE_ACTIONS();
        std::ostream &EOF_ACTIONS();
 
-       void COND_TRANSLATE( StateCond *stateCond, int level );
+       void COND_TRANSLATE( GenStateCond *stateCond, int level );
        void emitCondBSearch( RedStateAp *state, int level, int low, int high );
        void STATE_CONDS( RedStateAp *state, bool genDefault ); 
 
index 10413ac..259c752 100644 (file)
@@ -140,7 +140,7 @@ bool CSharpIpGotoCodeGen::IN_TRANS_ACTIONS( RedStateAp *state )
                                out << "        " << CS() << " = " << trans->targ->id << ";\n";
 
                        /* Write each action in the list. */
-                       for ( ActionTable::Iter item = trans->action->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = trans->action->key; item.lte(); item++ )
                                ACTION( out, item->value, trans->targ->id, false );
 
                        /* If the action contains a next then we need to reload, otherwise
@@ -167,7 +167,7 @@ void CSharpIpGotoCodeGen::GOTO_HEADER( RedStateAp *state )
        if ( state->toStateAction != 0 ) {
                /* Remember that we wrote an action. Write every action in the list. */
                anyWritten = true;
-               for ( ActionTable::Iter item = state->toStateAction->key; item.lte(); item++ )
+               for ( GenActionTable::Iter item = state->toStateAction->key; item.lte(); item++ )
                        ACTION( out, item->value, state->id, false );
        }
 
@@ -190,7 +190,7 @@ void CSharpIpGotoCodeGen::GOTO_HEADER( RedStateAp *state )
        if ( state->fromStateAction != 0 ) {
                /* Remember that we wrote an action. Write every action in the list. */
                anyWritten = true;
-               for ( ActionTable::Iter item = state->fromStateAction->key; item.lte(); item++ )
+               for ( GenActionTable::Iter item = state->fromStateAction->key; item.lte(); item++ )
                        ACTION( out, item->value, state->id, false );
        }
 
@@ -285,7 +285,7 @@ std::ostream &CSharpIpGotoCodeGen::FINISH_CASES()
                        anyWritten = true;
 
                        /* Write each action in the eof action list. */
-                       for ( ActionTable::Iter item = act->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = act->key; item.lte(); item++ )
                                ACTION( out, item->value, STATE_ERR_STATE, true );
                        out << "\tbreak;\n";
                }
@@ -338,7 +338,7 @@ void CSharpIpGotoCodeGen::setLabelsNeeded()
                         * invoked on characters (ie, not from out action code). */
                        if ( trans->action != 0 ) {
                                /* Loop the actions. */
-                               for ( ActionTable::Iter act = trans->action->key; act.lte(); act++ ) {
+                               for ( GenActionTable::Iter act = trans->action->key; act.lte(); act++ ) {
                                        /* Get the action and walk it's tree. */
                                        setLabelsNeeded( act->value->inlineList );
                                }
index 0c6444f..5aaee1e 100644 (file)
@@ -68,7 +68,7 @@ void CSharpSplitCodeGen::GOTO_HEADER( RedStateAp *state, bool stateInPartition )
        if ( state->toStateAction != 0 ) {
                /* Remember that we wrote an action. Write every action in the list. */
                anyWritten = true;
-               for ( ActionTable::Iter item = state->toStateAction->key; item.lte(); item++ )
+               for ( GenActionTable::Iter item = state->toStateAction->key; item.lte(); item++ )
                        ACTION( out, item->value, state->id, false );
        }
 
@@ -91,7 +91,7 @@ void CSharpSplitCodeGen::GOTO_HEADER( RedStateAp *state, bool stateInPartition )
        if ( state->fromStateAction != 0 ) {
                /* Remember that we wrote an action. Write every action in the list. */
                anyWritten = true;
-               for ( ActionTable::Iter item = state->fromStateAction->key; item.lte(); item++ )
+               for ( GenActionTable::Iter item = state->fromStateAction->key; item.lte(); item++ )
                        ACTION( out, item->value, state->id, false );
        }
 
@@ -154,7 +154,7 @@ std::ostream &CSharpSplitCodeGen::PART_TRANS( int partition )
                                        out << "        " << CS() << " = " << trans->targ->id << ";\n";
 
                                /* Write each action in the list. */
-                               for ( ActionTable::Iter item = trans->action->key; item.lte(); item++ )
+                               for ( GenActionTable::Iter item = trans->action->key; item.lte(); item++ )
                                        ACTION( out, item->value, trans->targ->id, false );
                        }
 
@@ -172,7 +172,7 @@ std::ostream &CSharpSplitCodeGen::PART_TRANS( int partition )
 
                        if ( st->toStateAction != 0 ) {
                                /* Remember that we wrote an action. Write every action in the list. */
-                               for ( ActionTable::Iter item = st->toStateAction->key; item.lte(); item++ )
+                               for ( GenActionTable::Iter item = st->toStateAction->key; item.lte(); item++ )
                                        ACTION( out, item->value, st->id, false );
                                genLineDirective( out );
                        }
@@ -463,7 +463,7 @@ void CSharpSplitCodeGen::setLabelsNeeded( RedStateAp *fromState, RedTransAp *tra
         * invoked on characters (ie, not from out action code). */
        if ( trans->action != 0 ) {
                /* Loop the actions. */
-               for ( ActionTable::Iter act = trans->action->key; act.lte(); act++ ) {
+               for ( GenActionTable::Iter act = trans->action->key; act.lte(); act++ ) {
                        /* Get the action and walk it's tree. */
                        setLabelsNeeded( fromState, act->value->inlineList );
                }
index c209d47..ab1a672 100644 (file)
@@ -95,7 +95,7 @@ std::ostream &CSharpTabCodeGen::TRANS_ACTION( RedTransAp *trans )
 std::ostream &CSharpTabCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -112,7 +112,7 @@ std::ostream &CSharpTabCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &CSharpTabCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -129,7 +129,7 @@ std::ostream &CSharpTabCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &CSharpTabCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -147,7 +147,7 @@ std::ostream &CSharpTabCodeGen::EOF_ACTION_SWITCH()
 std::ostream &CSharpTabCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -357,7 +357,7 @@ std::ostream &CSharpTabCodeGen::COND_KEYS()
        int totalTrans = 0;
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
                /* Loop the state's transitions. */
-               for ( StateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
+               for ( GenStateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
                        /* Lower key. */
                        out << ALPHA_KEY( sc->lowKey ) << ", ";
                        if ( ++totalTrans % IALL == 0 )
@@ -382,7 +382,7 @@ std::ostream &CSharpTabCodeGen::COND_SPACES()
        int totalTrans = 0;
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
                /* Loop the state's transitions. */
-               for ( StateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
+               for ( GenStateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
                        /* Cond Space id. */
                        out << sc->condSpace->condSpaceId << ", ";
                        if ( ++totalTrans % IALL == 0 )
@@ -896,13 +896,13 @@ void CSharpTabCodeGen::COND_TRANSLATE()
                                                        " + ((_mid - _keys)>>1)] ) {\n";
 
        for ( CondSpaceList::Iter csi = condSpaceList; csi.lte(); csi++ ) {
-               CondSpace *condSpace = csi;
+               GenCondSpace *condSpace = csi;
                out << "        case " << condSpace->condSpaceId << ": {\n";
                out << TABS(2) << "_widec = " << CAST(WIDE_ALPH_TYPE()) << "(" <<
                                KEY(condSpace->baseKey) << " + (" << GET_KEY() << 
                                " - " << KEY(keyOps->minKey) << "));\n";
 
-               for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+               for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                        out << TABS(2) << "if ( ";
                        CONDITION( out, *csi );
                        Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
index bcce3a1..8f900e9 100644 (file)
@@ -95,8 +95,8 @@ std::ostream &GraphvizDotGen::TRANS_ACTION( RedStateAp *fromState, RedTransAp *t
        
        /* Loop the existing actions and write out what's there. */
        for ( int a = 0; a < n; a++ ) {
-               for ( ActionTable::Iter actIt = actions[a]->key.first(); actIt.lte(); actIt++ ) {
-                       Action *action = actIt->value;
+               for ( GenActionTable::Iter actIt = actions[a]->key.first(); actIt.lte(); actIt++ ) {
+                       GenAction *action = actIt->value;
                        out << action->nameOrLoc();
                        if ( a < n-1 || !actIt.last() )
                                out << ", ";
@@ -109,8 +109,8 @@ std::ostream &GraphvizDotGen::ACTION( RedAction *action )
 {
        /* The action. */
        out << " / ";
-       for ( ActionTable::Iter actIt = action->key.first(); actIt.lte(); actIt++ ) {
-               Action *action = actIt->value;
+       for ( GenActionTable::Iter actIt = action->key.first(); actIt.lte(); actIt++ ) {
+               GenAction *action = actIt->value;
                if ( action->name != 0 )
                        out << action->name;
                else
@@ -124,7 +124,7 @@ std::ostream &GraphvizDotGen::ACTION( RedAction *action )
 std::ostream &GraphvizDotGen::ONCHAR( Key lowKey, Key highKey )
 {
        if ( lowKey > keyOps->maxKey ) {
-               CondSpace *condSpace = findCondSpace( lowKey, highKey );
+               GenCondSpace *condSpace = findCondSpace( lowKey, highKey );
                Key values = ( lowKey - condSpace->baseKey ) / keyOps->alphSize();
 
                lowKey = keyOps->minKey + 
@@ -138,7 +138,7 @@ std::ostream &GraphvizDotGen::ONCHAR( Key lowKey, Key highKey )
                }
                out << "(";
 
-               for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+               for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                        bool set = values & (1 << csi.pos());
                        if ( !set )
                                out << "!";
index 20560c2..8004236 100644 (file)
@@ -55,8 +55,6 @@ extern bool displayPrintables;
 
 extern int numSplitPartitions;
 
-/* Print a summary of the options. */
-
 /*
  * Callbacks invoked by the XML data parser.
  */
index a5789f7..16c8f66 100644 (file)
@@ -297,12 +297,12 @@ void JavaTabCodeGen::COND_TRANSLATE()
                ;
 
        for ( CondSpaceList::Iter csi = condSpaceList; csi.lte(); csi++ ) {
-               CondSpace *condSpace = csi;
+               GenCondSpace *condSpace = csi;
                out << "        case " << condSpace->condSpaceId << ": {\n";
                out << TABS(2) << "_widec = " << KEY(condSpace->baseKey) << 
                                " + (" << GET_KEY() << " - " << KEY(keyOps->minKey) << ");\n";
 
-               for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+               for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                        out << TABS(2) << "if ( ";
                        CONDITION( out, *csi );
                        Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
@@ -443,7 +443,7 @@ int JavaTabCodeGen::TRANS_ACTION( RedTransAp *trans )
 std::ostream &JavaTabCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -460,7 +460,7 @@ std::ostream &JavaTabCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &JavaTabCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -477,7 +477,7 @@ std::ostream &JavaTabCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &JavaTabCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -495,7 +495,7 @@ std::ostream &JavaTabCodeGen::EOF_ACTION_SWITCH()
 std::ostream &JavaTabCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -627,7 +627,7 @@ std::ostream &JavaTabCodeGen::COND_KEYS()
 {
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
                /* Loop the state's transitions. */
-               for ( StateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
+               for ( GenStateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
                        /* Lower key. */
                        ARRAY_ITEM( KEY( sc->lowKey ), false );
                        ARRAY_ITEM( KEY( sc->highKey ), false );
@@ -644,7 +644,7 @@ std::ostream &JavaTabCodeGen::COND_SPACES()
 {
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
                /* Loop the state's transitions. */
-               for ( StateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
+               for ( GenStateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
                        /* Cond Space id. */
                        ARRAY_ITEM( KEY( sc->condSpace->condSpaceId ), false );
                }
@@ -1298,7 +1298,7 @@ std::ostream &JavaTabCodeGen::ACTIONS_ARRAY()
                /* Write out the length, which will never be the last character. */
                ARRAY_ITEM( INT(act->key.length()), false );
 
-               for ( ActionTable::Iter item = act->key; item.lte(); item++ )
+               for ( GenActionTable::Iter item = act->key; item.lte(); item++ )
                        ARRAY_ITEM( INT(item->value->actionId), (act.last() && item.last()) );
        }
        return out;
@@ -1559,7 +1559,7 @@ void JavaTabCodeGen::SUB_ACTION( ostream &ret, GenInlineItem *item,
        }
 }
 
-void JavaTabCodeGen::ACTION( ostream &ret, Action *action, int targState, bool inFinish )
+void JavaTabCodeGen::ACTION( ostream &ret, GenAction *action, int targState, bool inFinish )
 {
        /* Write the preprocessor line info for going into the source file. */
        javaLineDirective( ret, sourceFileName, action->loc.line );
@@ -1570,7 +1570,7 @@ void JavaTabCodeGen::ACTION( ostream &ret, Action *action, int targState, bool i
        ret << "}\n";
 }
 
-void JavaTabCodeGen::CONDITION( ostream &ret, Action *condition )
+void JavaTabCodeGen::CONDITION( ostream &ret, GenAction *condition )
 {
        ret << "\n";
        javaLineDirective( ret, sourceFileName, condition->loc.line );
index 1dd3a99..2e777be 100644 (file)
@@ -117,8 +117,8 @@ public:
        string TABS( int level );
        string KEY( Key key );
        string INT( int i );
-       void ACTION( ostream &ret, Action *action, int targState, bool inFinish );
-       void CONDITION( ostream &ret, Action *condition );
+       void ACTION( ostream &ret, GenAction *action, int targState, bool inFinish );
+       void CONDITION( ostream &ret, GenAction *condition );
        string ALPH_TYPE();
        string WIDE_ALPH_TYPE();
        string ARRAY_TYPE( unsigned long maxVal );
index 4bcf0df..c67aed3 100644 (file)
@@ -58,7 +58,7 @@ std::ostream &RbxGotoCodeGen::TRANS_GOTO( RedTransAp *trans, int level )
 std::ostream &RbxGotoCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -74,7 +74,7 @@ std::ostream &RbxGotoCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &RbxGotoCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -90,7 +90,7 @@ std::ostream &RbxGotoCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &RbxGotoCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -106,7 +106,7 @@ std::ostream &RbxGotoCodeGen::EOF_ACTION_SWITCH()
 std::ostream &RbxGotoCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -259,14 +259,14 @@ void RbxGotoCodeGen::STATE_GOTO_ERROR()
        rbxGoto(out << "        ", "_out") << "\n";
 }
 
-void RbxGotoCodeGen::COND_TRANSLATE( StateCond *stateCond, int level )
+void RbxGotoCodeGen::COND_TRANSLATE( GenStateCond *stateCond, int level )
 {
-       CondSpace *condSpace = stateCond->condSpace;
+       GenCondSpace *condSpace = stateCond->condSpace;
        out << TABS(level) << "_widec = " <<
                KEY(condSpace->baseKey) << " + (" << GET_KEY() << 
                " - " << KEY(keyOps->minKey) << ");\n";
 
-       for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+       for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                out << TABS(level) << "if ";
                CONDITION( out, *csi );
                Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
@@ -278,7 +278,7 @@ void RbxGotoCodeGen::emitCondBSearch( RedStateAp *state, int level, int low, int
 {
        /* Get the mid position, staying on the lower end of the range. */
        int mid = (low + high) >> 1;
-       StateCond **data = state->stateCondVect.data;
+       GenStateCond **data = state->stateCondVect.data;
 
        /* Determine if we need to look higher or lower. */
        bool anyLower = mid > low;
index 5ec9f5c..e779f0a 100644 (file)
@@ -59,7 +59,7 @@ public:
         int FROM_STATE_ACTION( RedStateAp *state );
         int EOF_ACTION( RedStateAp *state );
 
-       void COND_TRANSLATE( StateCond *stateCond, int level );
+       void COND_TRANSLATE( GenStateCond *stateCond, int level );
        void emitCondBSearch( RedStateAp *state, int level, int low, int high );
        void STATE_CONDS( RedStateAp *state, bool genDefault ); 
 
index 1a8693c..1c7c674 100644 (file)
@@ -238,7 +238,7 @@ string RubyCodeGen::FSM_NAME()
 }
 
 
-void RubyCodeGen::ACTION( ostream &ret, Action *action, int targState, bool inFinish )
+void RubyCodeGen::ACTION( ostream &ret, GenAction *action, int targState, bool inFinish )
 {
        /* Write the preprocessor line info for going into the source file. */
        rubyLineDirective( ret, sourceFileName, action->loc.line );
@@ -312,7 +312,7 @@ string RubyCodeGen::INT( int i )
        return ret.str();
 }
 
-void RubyCodeGen::CONDITION( ostream &ret, Action *condition )
+void RubyCodeGen::CONDITION( ostream &ret, GenAction *condition )
 {
        ret << "\n";
        rubyLineDirective( ret, sourceFileName, condition->loc.line );
@@ -375,7 +375,7 @@ std::ostream &RubyCodeGen::ACTIONS_ARRAY()
                /* Write out the length, which will never be the last character. */
                ARRAY_ITEM( INT(act->key.length()), ++totalActions, false );
 
-               for ( ActionTable::Iter item = act->key; item.lte(); item++ ) {
+               for ( GenActionTable::Iter item = act->key; item.lte(); item++ ) {
                        ARRAY_ITEM( INT(item->value->actionId), ++totalActions, (act.last() && item.last()) );
                }
        }
index 5a7aae2..7516b67 100644 (file)
@@ -56,14 +56,14 @@ protected:
         void INLINE_LIST(ostream &ret, GenInlineList *inlineList, int targState, bool inFinish);
         string ACCESS();
 
-        void ACTION( ostream &ret, Action *action, int targState, bool inFinish );
+        void ACTION( ostream &ret, GenAction *action, int targState, bool inFinish );
        string GET_KEY();
         string GET_WIDE_KEY();
        string GET_WIDE_KEY( RedStateAp *state );
        string KEY( Key key );
        string TABS( int level );
        string INT( int i );
-       void CONDITION( ostream &ret, Action *condition );
+       void CONDITION( ostream &ret, GenAction *condition );
        string ALPH_TYPE();
        string WIDE_ALPH_TYPE();
        string ARRAY_TYPE( unsigned long maxVal );
index d2eca2e..e099071 100644 (file)
@@ -164,7 +164,7 @@ std::ostream &RubyFFlatCodeGen::TO_STATE_ACTION_SWITCH()
                        out << "\twhen " << redAct->actListId+1 << " then\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
                }
        }
@@ -184,7 +184,7 @@ std::ostream &RubyFFlatCodeGen::FROM_STATE_ACTION_SWITCH()
                        out << "\twhen " << redAct->actListId+1 << " then\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
                }
        }
@@ -202,7 +202,7 @@ std::ostream &RubyFFlatCodeGen::EOF_ACTION_SWITCH()
                        out << "\twhen " << redAct->actListId+1 << " then\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, true );
                }
        }
@@ -222,7 +222,7 @@ std::ostream &RubyFFlatCodeGen::ACTION_SWITCH()
                        out << "\twhen " << redAct->actListId+1 << " then\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                }
index d95ddac..5adc20c 100644 (file)
@@ -31,7 +31,7 @@ using std::string;
 std::ostream &RubyFlatCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -47,7 +47,7 @@ std::ostream &RubyFlatCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &RubyFlatCodeGen::FROM_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -63,7 +63,7 @@ std::ostream &RubyFlatCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &RubyFlatCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -79,7 +79,7 @@ std::ostream &RubyFlatCodeGen::EOF_ACTION_SWITCH()
 std::ostream &RubyFlatCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break */
@@ -324,13 +324,13 @@ void RubyFlatCodeGen::COND_TRANSLATE()
        out <<
                "       case _cond \n";
        for ( CondSpaceList::Iter csi = condSpaceList; csi.lte(); csi++ ) {
-               CondSpace *condSpace = csi;
+               GenCondSpace *condSpace = csi;
                out << "        when " << condSpace->condSpaceId + 1 << " then\n";
                out << TABS(2) << "_widec = " << "(" <<
                                KEY(condSpace->baseKey) << " + (" << GET_KEY() << 
                                " - " << KEY(keyOps->minKey) << "))\n";
 
-               for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+               for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                        out << TABS(2) << "if ( ";
                        CONDITION( out, *csi );
                        Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
index 61eba5d..63caa27 100644 (file)
@@ -140,7 +140,7 @@ std::ostream &RubyFTabCodeGen::TO_STATE_ACTION_SWITCH()
                        out << "\twhen " << redAct->actListId+1 << " then\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                }
@@ -161,7 +161,7 @@ std::ostream &RubyFTabCodeGen::FROM_STATE_ACTION_SWITCH()
                        out << "\twhen " << redAct->actListId+1 << " then\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                }
@@ -180,7 +180,7 @@ std::ostream &RubyFTabCodeGen::EOF_ACTION_SWITCH()
                        out << "\twhen " << redAct->actListId+1 << " then\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, true );
 
                }
@@ -201,7 +201,7 @@ std::ostream &RubyFTabCodeGen::ACTION_SWITCH()
                        out << "\twhen " << redAct->actListId+1 << " then\n";
 
                        /* Write each action in the list of action items. */
-                       for ( ActionTable::Iter item = redAct->key; item.lte(); item++ )
+                       for ( GenActionTable::Iter item = redAct->key; item.lte(); item++ )
                                ACTION( out, item->value, 0, false );
 
                }
index 3d39ae1..c1fef8a 100644 (file)
@@ -158,12 +158,12 @@ void RubyTabCodeGen::COND_TRANSLATE()
                                                        " + ((_mid - _keys)>>1)]\n";
 
        for ( CondSpaceList::Iter csi = condSpaceList; csi.lte(); csi++ ) {
-               CondSpace *condSpace = csi;
+               GenCondSpace *condSpace = csi;
                out << "        when " << condSpace->condSpaceId << " then" ;
                out << "        _widec = " << KEY(condSpace->baseKey) << 
                                "+ (" << GET_KEY() << " - " << KEY(keyOps->minKey) << ")\n";
 
-               for ( CondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
+               for ( GenCondSet::Iter csi = condSpace->condSet; csi.lte(); csi++ ) {
                        Size condValOffset = ((1 << csi.pos()) * keyOps->alphSize());
                        out << "        _widec += " << condValOffset << " if ( ";
                        CONDITION( out, *csi );
@@ -444,7 +444,7 @@ void RubyTabCodeGen::writeExec()
 std::ostream &RubyTabCodeGen::FROM_STATE_ACTION_SWITCH() 
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numFromStateRefs > 0 ) {
                        /* Write the case label, the action */
@@ -461,7 +461,7 @@ std::ostream &RubyTabCodeGen::FROM_STATE_ACTION_SWITCH()
 std::ostream &RubyTabCodeGen::TO_STATE_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numToStateRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -477,7 +477,7 @@ std::ostream &RubyTabCodeGen::TO_STATE_ACTION_SWITCH()
 std::ostream &RubyTabCodeGen::EOF_ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numEofRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -493,7 +493,7 @@ std::ostream &RubyTabCodeGen::EOF_ACTION_SWITCH()
 std::ostream &RubyTabCodeGen::ACTION_SWITCH()
 {
        /* Walk the list of functions, printing the cases. */
-       for ( ActionList::Iter act = actionList; act.lte(); act++ ) {
+       for ( GenActionList::Iter act = actionList; act.lte(); act++ ) {
                /* Write out referenced actions. */
                if ( act->numTransRefs > 0 ) {
                        /* Write the case label, the action and the case break. */
@@ -691,7 +691,7 @@ std::ostream &RubyTabCodeGen::COND_KEYS()
        int totalTrans = 0;
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
                /* Loop the state's transitions. */
-               for ( StateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
+               for ( GenStateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
                        /* Lower key. */
                        ARRAY_ITEM( KEY( sc->lowKey ), ++totalTrans, false );
                        ARRAY_ITEM( KEY( sc->highKey ), ++totalTrans, false );
@@ -711,7 +711,7 @@ std::ostream &RubyTabCodeGen::COND_SPACES()
        int totalTrans = 0;
        for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) {
                /* Loop the state's transitions. */
-               for ( StateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
+               for ( GenStateCondList::Iter sc = st->stateCondList; sc.lte(); sc++ ) {
                        /* Cond Space id. */
                        ARRAY_ITEM( KEY( sc->condSpace->condSpaceId ), ++totalTrans, false );
                }