Fix bug in NfaExtensions.ToGrammarDocument that caused exemplification to fail.