Skip to content
Snippets Groups Projects
Commit 38a78483 authored by Tomáš Pecka's avatar Tomáš Pecka
Browse files

Fix typo in Glushkov

parent 748182c6
No related branches found
No related tags found
No related merge requests found
...@@ -38,7 +38,7 @@ FSM Glushkov::convert( void ) ...@@ -38,7 +38,7 @@ FSM Glushkov::convert( void )
constructBeginSymbolSet( ); constructBeginSymbolSet( );
constructNeighbourSymbolSet( ); constructNeighbourSymbolSet( );
constructEndSymbolSet( ); constructEndSymbolSet( );
// q0 check is in step 7 // \e in q0 check is in step 7
   
// step 5 // step 5
State q0( "q0" ); State q0( "q0" );
...@@ -50,12 +50,13 @@ FSM Glushkov::convert( void ) ...@@ -50,12 +50,13 @@ FSM Glushkov::convert( void )
// step 6 // step 6
for( const auto & ns : m_beginSymbolSet ) for( const auto & ns : m_beginSymbolSet )
m_fsm.addTransition( q0, ns.m_alphabetSymbol, ns.m_state ); m_fsm.addTransition( q0, ns.m_alphabetSymbol, ns.m_state );
for( const auto & ns : m_neighbourSymbolSet ) for( const auto & ns : m_neighbourSymbolSet )
{ {
const NumberedSymbol & first = m_numberedSymbols.find( ns.m_first )->second; const NumberedSymbol & first = m_numberedSymbols.find( ns.m_first )->second;
const NumberedSymbol & second = m_numberedSymbols.find( ns.m_second )->second; const NumberedSymbol & second = m_numberedSymbols.find( ns.m_second )->second;
   
m_fsm.addTransition( first.m_state, second.m_alphabetSymbol, first.m_state ); m_fsm.addTransition( first.m_state, second.m_alphabetSymbol, second.m_state );
} }
   
// step 7 // step 7
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment