mirror of
https://github.com/cwbaker/lalr.git
synced 2026-09-26 16:33:18 +03:00
24 lines
586 B
C++
24 lines
586 B
C++
#ifndef LALR_LEXERTRANSITION_HPP_INCLUDED
|
|
#define LALR_LEXERTRANSITION_HPP_INCLUDED
|
|
|
|
namespace lalr
|
|
{
|
|
|
|
class LexerState;
|
|
class LexerAction;
|
|
|
|
/**
|
|
// A transition in a lexical analyzer's state machine.
|
|
*/
|
|
class LexerTransition
|
|
{
|
|
public:
|
|
int begin; ///< The first character that the transition can be made on.
|
|
int end; ///< One past the last character that the transition can be made on.
|
|
const LexerState* state; ///< The state that is transitioned to.
|
|
const LexerAction* action; ///< The action that is taken on the transition or null if no action is taken.
|
|
};
|
|
|
|
}
|
|
|
|
#endif
|