From eee70ce54ca6039885c6defd0334f7c15b217bea Mon Sep 17 00:00:00 2001 From: thurston Date: Thu, 14 Feb 2008 19:12:37 +0000 Subject: [PATCH] Print any actions that are in State::eofTrans. These come from scanners only. git-svn-id: svn://mambo.cs.queensu.ca/ragel/trunk@414 052ea7fc-9027-0410-9066-f65837a77df0 --- rlgen-dot/gvdotgen.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/rlgen-dot/gvdotgen.cpp b/rlgen-dot/gvdotgen.cpp index 3cdff55..631f3cb 100644 --- a/rlgen-dot/gvdotgen.cpp +++ b/rlgen-dot/gvdotgen.cpp @@ -241,6 +241,8 @@ void GraphvizDotGen::writeDotFile( ) /* Psuedo states for final states with eof actions. */ for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) { + if ( st->eofTrans != 0 && st->eofTrans->action != 0 ) + out << " eof_" << st->id << ";\n"; if ( st->eofAction != 0 ) out << " eof_" << st->id << ";\n"; } @@ -295,6 +297,11 @@ void GraphvizDotGen::writeDotFile( ) /* Out action transitions. */ for ( RedStateList::Iter st = redFsm->stateList; st.lte(); st++ ) { + if ( st->eofTrans != 0 && st->eofTrans->action != 0 ) { + out << " " << st->id << " -> eof_" << + st->id << " [ label = \"EOF"; + ACTION( st->eofTrans->action ) << "\" ];\n"; + } if ( st->eofAction != 0 ) { out << " " << st->id << " -> eof_" << st->id << " [ label = \"EOF"; -- 2.11.4.GIT