LR0: Made Item a public class, for testing

This commit is contained in:
Paul Beckingham 2015-12-27 12:02:00 -05:00
parent 6b4448ec8a
commit 66504d5dfc
2 changed files with 2 additions and 3 deletions

View file

@ -158,7 +158,7 @@ std::string LR0::dump (std::vector <std::vector <std::string>>& augmented, State
*/ */
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
LR0::Item::Item (std::vector <std::string>& rule) LR0::Item::Item (const std::vector <std::string>& rule)
: _rule (rule) : _rule (rule)
, _cursor (2) , _cursor (2)
{ {

View file

@ -40,11 +40,10 @@ public:
void debug (bool); void debug (bool);
std::string dump () const; std::string dump () const;
protected:
class Item class Item
{ {
public: public:
Item (std::vector <std::string>&); Item (const std::vector <std::string>&);
bool advance (); bool advance ();
private: private: