tc39 / ecmarkup

An HTML superset/Markdown subset source format for ECMAScript and related specifications
https://tc39.es/ecmarkup/
MIT License
221 stars 63 forks source link

`declared` vs. `<ins>` or `<del>` #528

Closed justingrant closed 1 year ago

justingrant commented 1 year ago

When [declared="s"] is wrapped in an <ins> or <del>, it no longer works.

Example:

1. <ins>[declared="s"] Let _systemTimeZoneString_ be the String representing the host environment's current time zone, either a primary time zone identifier or a String _s_ for which ParseText(StringToCodePoints(_s_), |NormalizedUTCOffset|) returns a Parse Node.</ins>

Expected: OK

Actual: could not find a preceding declaration for "s"

The same text works fine if I remove the <ins>.

bakkot commented 1 year ago

I suspect it will work if you put the [declared="s"] outside of the <ins>.

justingrant commented 1 year ago

Cool, that works. Thanks!

bakkot commented 1 year ago

I think actually changing the behavior here is going to be more trouble than it's worth, so I documented it as a restriction instead. Going to close as wontfix for the moment.