Right I get that, but the entry and exit states are special, created
alongside each new nonterminal. That's why their constructors should be
package private, because the user never calls them.
On Mar 28, 2014 6:22 PM, "Radu Mereuta" <notifications@github.com> wrote:

> In src/javasources/KTool/src/org/kframework/parser/concrete2/Grammar.java:
>
> > +            if (!nt.equals(state.nt)) return false;
> > +            if (!stateId.equals(state.stateId)) return false;
> > +
> > +            return true;
> > +        }
> > +
> > +        @Override
> > +        public int hashCode() {
> > +            int result = stateId.hashCode();
> > +            //result = 31 * result + nt.hashCode();
> > +            return result;
> > +        }
> > +    }
> > +
> > +    public static class ExitState extends State {
> > +        public ExitState(StateId stateId, NonTerminal nt) {
>
> We may want to make the parser available as standalone, and different
> front ends generate the grammar states for the kernel.
> This requires access to the states, so public is the correct descriptor.
>
> --
> Reply to this email directly or view it on GitHub<https://github.com/kframework/k/pull/318/files#r11089697>
> .
>