fix incorrect indexing of lexical productions when disc=False