action traversal and store these properties in some traversal descriptor.
git-svn-id: http://svn.complang.org/ragel/trunk@430
052ea7fc-9027-0410-9066-
f65837a77df0
}
void FsmCodeGen::LM_SWITCH( ostream &ret, InlineItem *item,
}
void FsmCodeGen::LM_SWITCH( ostream &ret, InlineItem *item,
- int targState, int inFinish )
+ int targState, int inFinish, bool csForced )
{
ret <<
" switch( " << ACT() << " ) {\n";
{
ret <<
" switch( " << ACT() << " ) {\n";
/* Write the block and close it off. */
ret << " {";
/* Write the block and close it off. */
ret << " {";
- INLINE_LIST( ret, lma->children, targState, inFinish, false );
+ INLINE_LIST( ret, lma->children, targState, inFinish, csForced );
ret << "}\n";
ret << " break;\n";
ret << "}\n";
ret << " break;\n";
}
void FsmCodeGen::SUB_ACTION( ostream &ret, InlineItem *item,
}
void FsmCodeGen::SUB_ACTION( ostream &ret, InlineItem *item,
- int targState, bool inFinish )
+ int targState, bool inFinish, bool csForced )
{
if ( item->children->length() > 0 ) {
/* Write the block and close it off. */
ret << "{";
{
if ( item->children->length() > 0 ) {
/* Write the block and close it off. */
ret << "{";
- INLINE_LIST( ret, item->children, targState, inFinish, false );
+ INLINE_LIST( ret, item->children, targState, inFinish, csForced );
NEXT_EXPR( ret, item, inFinish );
break;
case InlineItem::LmSwitch:
NEXT_EXPR( ret, item, inFinish );
break;
case InlineItem::LmSwitch:
- LM_SWITCH( ret, item, targState, inFinish );
+ LM_SWITCH( ret, item, targState, inFinish, csForced );
break;
case InlineItem::LmSetActId:
SET_ACT( ret, item );
break;
case InlineItem::LmSetActId:
SET_ACT( ret, item );
SET_TOKSTART( ret, item );
break;
case InlineItem::SubAction:
SET_TOKSTART( ret, item );
break;
case InlineItem::SubAction:
- SUB_ACTION( ret, item, targState, inFinish );
+ SUB_ACTION( ret, item, targState, inFinish, csForced );
break;
case InlineItem::Break:
BREAK( ret, targState, csForced );
break;
case InlineItem::Break:
BREAK( ret, targState, csForced );
virtual void CURS( ostream &ret, bool inFinish ) = 0;
virtual void TARGS( ostream &ret, bool inFinish, int targState ) = 0;
void EXEC( ostream &ret, InlineItem *item, int targState, int inFinish );
virtual void CURS( ostream &ret, bool inFinish ) = 0;
virtual void TARGS( ostream &ret, bool inFinish, int targState ) = 0;
void EXEC( ostream &ret, InlineItem *item, int targState, int inFinish );
- void LM_SWITCH( ostream &ret, InlineItem *item, int targState, int inFinish );
+ void LM_SWITCH( ostream &ret, InlineItem *item, int targState,
+ int inFinish, bool csForced );
void SET_ACT( ostream &ret, InlineItem *item );
void INIT_TOKSTART( ostream &ret, InlineItem *item );
void INIT_ACT( ostream &ret, InlineItem *item );
void SET_ACT( ostream &ret, InlineItem *item );
void INIT_TOKSTART( ostream &ret, InlineItem *item );
void INIT_ACT( ostream &ret, InlineItem *item );
void SET_TOKEND( ostream &ret, InlineItem *item );
void GET_TOKEND( ostream &ret, InlineItem *item );
void SUB_ACTION( ostream &ret, InlineItem *item,
void SET_TOKEND( ostream &ret, InlineItem *item );
void GET_TOKEND( ostream &ret, InlineItem *item );
void SUB_ACTION( ostream &ret, InlineItem *item,
- int targState, bool inFinish );
+ int targState, bool inFinish, bool csForced );
void STATE_IDS();
string ERROR_STATE();
void STATE_IDS();
string ERROR_STATE();