-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Remove parse error for <template><tr></tr> </template> #8271
Conversation
The spec would enable foster parenting for whitespace in template after seeing table-related markup and trigger a parse error. Whitespace in template should not be a parse error. This change should not affect the parsed tree structure, only the number of parse errors. Non-whitespace text will still go through foster parenting and is still a parse error. Fixes #7922.
Checking Firefox's view source and in https://validator.nu for
there is no parse error reported (but non-whitespace there is reported), so the implementation already seems to match this change. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not entirely sure I understand the parser enough to give a good review, but this makes some sense, and I'm happy for it to be merged.
Unfortunately not. Instead, it looks like an intermediate spec change remains unimplemented. 😬 |
Please don't let this be blocked on my review. I have a hard time reviewing this, because I discovered that I need to catch up on older spec changes. Specifically, https://searchfox.org/whatwg-html/diff/98c83e5eb83be811cc2534af7c44664a19981d39/source#100001 and https://searchfox.org/whatwg-html/diff/301fe28ae2ee46fab52676abff5f3c3560f795f1/source#77256 . |
OK, thanks @hsivonen. Then I think we should merge, as @alexander-akait has implemented it in swc-project/swc#5779 and the tests pass there. |
See whatwg/html#8271 Co-authored-by: Simon Pieters <zcorpan@gmail.com>
and update to the latest html5lib-tests See: - whatwg/html#7922 - whatwg/html#8271 - html5lib/html5lib-tests#150 - html5lib/html5lib-tests#151
and update to the latest html5lib-tests See: - whatwg/html#7922 - whatwg/html#8271 - html5lib/html5lib-tests#150 - html5lib/html5lib-tests#151
See whatwg/html#8271 Also removed test patches which are no longer needed, and fixed a bug exposed by new tests The testsuite includes tests for the new <search> element, but this is not included in the specification yet, so the tests have been suppressed
189aee2 fix KR style function declarations for C2X compilers 5f16d4c fix omissions from change long [skipci] d89915b archive setup.py 23decb0 created updated local (controllable) copy of html5lib tests 382e8f4 unlink dated html5lib tests 10567da fixes to make sigil-gumbo pass html5lib tree-construction tests 7630679 restructure and simplify everything f907c01 fix parse error by template misuse in table see whatwg/html#8271 20e7be7 correctly handle text in form elements ala nokogirl commit 73c5df2 4469240 prevent very minor memory leak git-subtree-dir: gumbo_subtree git-subtree-split: 189aee231c525a17a8b6b0615b93df45aaee2c8f
The spec would enable foster parenting for whitespace in template after seeing table-related markup and trigger a parse error. Whitespace in template should not be a parse error. This change should not affect the parsed tree structure, only the number of parse errors. Non-whitespace text will still go through foster parenting and is still a parse error.
Fixes #7922.
cc @whatwg/html-parser
(See WHATWG Working Mode: Changes for more details.)
/parsing.html ( diff )