Fails to parse a comment with a single character inside #2

Closed
opened 2022-12-18 22:39:47 +01:00 by siefkenj · 1 comment
siefkenj commented 2022-12-18 22:39:47 +01:00 (Migrated from github.com)

parser.parse("<!--x-->")

produces Document(Comment(⚠),Text) instead of Document(Comment) as I would expect.

I looked through the grammar and don't understand where this bug is...It works for zero-character comments and 2 character comments, just not one-character ones.

`parser.parse("<!--x-->")` produces `Document(Comment(⚠),Text)` instead of `Document(Comment)` as I would expect. I looked through the grammar and don't understand where this bug is...It works for zero-character comments and 2 character comments, just not one-character ones.
marijnh commented 2022-12-19 08:35:44 +01:00 (Migrated from github.com)

Attached patch should help.

Attached patch should help.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lezer/xml#2
No description provided.