# include "../lexgen1/ldefs.c"
rdrule()
{
	int ks, ns;
	char store[200];
lineno--;
for(nstart=ns=nstate; --ns > 1; )
	{
	addslide (ns, ns%2 ? 1 :2);
	if (ns%2==0)
		addslide(ns,ns-1);
	}
for (ks=1; ks < NRULES; ks++)
	{
	if (!rdcomm(store, ks)) break;
	if (store[0]==0) {ks--; continue;}
	ns = makeauto(store, ks);
	addstop(ns, ks);
	if (ns>NST) error("too many states");
	}
lineno++;
if (ks <= 1) head2();
return(ks);
}
