Skip to content

Allow comments to end with <!--> #1456

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 23, 2016
Merged

Allow comments to end with <!--> #1456

merged 2 commits into from
Jun 23, 2016

Conversation

zcorpan
Copy link
Member

@zcorpan zcorpan commented Jun 22, 2016

Introduce a new state in the parser to not give a parse error
when a comment ends with "<!-->".

It is common to use conditional comments for legacy IE like this:

<!--[if gt IE 9]><!--> ... <!--<![endif]-->

This regressed in 518d16f.

Fixes #1453.

Introduce a new state in the parser to not give a parse error
when a comment ends with "<!-->".

It is common to use conditional comments for legacy IE like this:

<!--[if gt IE 9]><!--> ... <!--<![endif]-->

This regressed in 518d16f.

Fixes #1453.
@zcorpan
Copy link
Member Author

zcorpan commented Jun 22, 2016

@eel-in-a-hovercraft Thanks for bringing this issue to our attention. Would you like to have your name in the spec's Acknowledgements, and if so under what name?

@annevk
Copy link
Member

annevk commented Jun 22, 2016

Do we expect more fallout? How many implementations do we have now of the new comment states? I'm a little worried that we are tinkering too much with something that was fairly robust.

@sideshowbarker
Copy link
Member

Do we expect more fallout?

No. We should have anticipated this one.

User-facing behavior for this has been in the W3C HTML checker getting hit with a dozen requests or more every second, and this is the only unexpected change any users have reported so far.

How many implementations do we have now of the new comment states?

Just one: The parser used by the HTML parser. No browser implementations yet. But it’s only been in the spec for one day so far…

@zcorpan
Copy link
Member Author

zcorpan commented Jun 22, 2016

@eel-in-a-hovercraft
Copy link

Thank YOU. Having my name in the acknowledgements would be great. Put me in
as Marc-André Choquette.

Thanks again.
On Jun 22, 2016 05:53, "Simon Pieters" notifications@github.com wrote:

@eel-in-a-hovercraft https://github.com/eel-in-a-hovercraft Thanks for
bringing this issue to our attention. Would you like to have your name in
the spec's Acknowledgements, and if so under what name?


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#1456 (comment), or mute
the thread
https://github.com/notifications/unsubscribe/AFjj6hnJ0OQ6pJ_rOYm738fGCiFrMlRVks5qOQYPgaJpZM4I7hCM
.

@zcorpan
Copy link
Member Author

zcorpan commented Jun 22, 2016

Awesome, added you. 👍

@zcorpan
Copy link
Member Author

zcorpan commented Jun 23, 2016

I think this is ready to merge.

@domenic domenic merged commit 1633b9a into master Jun 23, 2016
@domenic domenic deleted the allow-conditional-comments branch June 23, 2016 16:20
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Dec 5, 2016
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request May 18, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request May 19, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request May 19, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request May 19, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request May 19, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jul 4, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jul 5, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jul 7, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Oct 8, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Oct 8, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Dec 14, 2017
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Feb 6, 2018
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Mar 16, 2018
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Mar 16, 2018
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Mar 16, 2018
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Nov 16, 2018
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Dec 15, 2018
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Dec 17, 2018
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Dec 18, 2018
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jan 15, 2019
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Apr 28, 2019
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jul 5, 2019
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Nov 26, 2019
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jan 15, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Feb 12, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Feb 13, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Mar 4, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Apr 23, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Apr 24, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Apr 25, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jun 18, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
hsivonen pushed a commit to hsivonen/gecko that referenced this pull request Jul 3, 2020
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jul 4, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Jul 4, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Aug 3, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Aug 5, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Aug 10, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
sideshowbarker added a commit to validator/htmlparser that referenced this pull request Aug 21, 2020
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Aug 16, 2021
hsivonen pushed a commit to validator/htmlparser that referenced this pull request Aug 17, 2021
Also allow `<!-->` at (IE conditional) comment end

See whatwg/html#1356
See whatwg/html#1456
jamienicol pushed a commit to jamienicol/gecko that referenced this pull request Aug 20, 2021
i3roly pushed a commit to i3roly/firefox-dynasty that referenced this pull request Jun 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

5 participants