chat: fix an "oldie but goodie" grammar generator bug that surfaced during last changes (#24653)

* chat: fix an "oldie but goodie" grammar generator bug that surfaced during last changes

* update erroneous case in PEG parser test
This commit is contained in:
Piotr Wilkin (ilintar)
2026-06-15 15:27:47 +02:00
committed by GitHub
parent e3cab403bf
commit 0ae3f450f0
3 changed files with 78 additions and 3 deletions
+1 -1
View File
@@ -129,7 +129,7 @@ void test_gbnf_generation(testing &t) {
});
assert_gbnf_equal(t, R"""(
root ::= ([^<] | "<" [^/] | "</" [^t] | "</t" [^a] | "</ta" [^g] | "</tag" [^>])*
root ::= ([^<] | "<" [^/] | "</" [^t] | "</t" [^a] | "</ta" [^g] | "</tag" [^>])* ("<" | "</" | "</t" | "</ta" | "</tag")?
space ::= | " " | "\n"{1,2} [ \t]{0,20}
)""", gbnf);
});