mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-07-07 20:06:39 +02:00
LR0: Added ::Item::done
This commit is contained in:
parent
fbcb79006e
commit
29130e9d4c
2 changed files with 7 additions and 0 deletions
|
@ -185,6 +185,12 @@ bool LR0::Item::advance ()
|
|||
return true;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
bool LR0::Item::done () const
|
||||
{
|
||||
return _cursor >= _rule.size ();
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
std::string LR0::Item::dump () const
|
||||
{
|
||||
|
|
|
@ -46,6 +46,7 @@ public:
|
|||
Item (const std::vector <std::string>&);
|
||||
void setGrammarRuleIndex (const int);
|
||||
bool advance ();
|
||||
bool done () const;
|
||||
std::string dump () const;
|
||||
|
||||
private:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue