Skip to content
Permalink
Browse files

[giowct] (3) PARSER: Add a parse error for non-space characters in <t…

…able> elements

Affected topics: HTML Syntax and Parsing


git-svn-id: http://svn.whatwg.org/webapps@8665 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Jun 9, 2014
1 parent b97eb3a commit dab72ccea3b31bb74489358c6be5d7cc1cfe8ead
Showing with 26 additions and 11 deletions.
  1. +9 −4 complete.html
  2. +9 −4 index
  3. +8 −3 source
</script><body onload=init()>
<header class="head with-buttons" id=head><p><a href=//www.whatwg.org/ class=logo><img width=101 src=/images/logo alt=WHATWG height=101></a></p>
<hgroup><h1 class=allcaps>HTML</h1>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 8 June 2014</h2>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 9 June 2014</h2>
</hgroup><div>
<div>
<a href=//whatwg.org/html><span><strong>Multipage Version</strong> <code>whatwg.org/html</code></span></a>
from the following list:</p>

<dl class=switch><dt>If <a href=#foster-parent title="foster parent">foster parenting</a> is enabled and <var title="">target</var> is a <code><a href=#the-table-element>table</a></code>, <code><a href=#the-tbody-element>tbody</a></code>, <code><a href=#the-tfoot-element>tfoot</a></code>,
<code><a href=#the-thead-element>thead</a></code>, or <code><a href=#the-tr-element>tr</a></code> element</dt>
<code><a href=#the-thead-element>thead</a></code>, or <code><a href=#the-tr-element>tr</a></code> element</dt> <!-- same list as handling of characters
in "in table" mode -->

<dd>

<p>When the user agent is to apply the rules for the "<a href=#parsing-main-intable title="insertion mode: in table">in
table</a>" <a href=#insertion-mode>insertion mode</a>, the user agent must handle the token as follows:</p>

<dl class=switch><dt>A character token, if the <a href=#current-node>current node</a> is <code><a href=#the-table-element>table</a></code>, <code><a href=#the-tbody-element>tbody</a></code>, <code><a href=#the-tfoot-element>tfoot</a></code>, <code><a href=#the-thead-element>thead</a></code>, or <code><a href=#the-tr-element>tr</a></code> element</dt>
<dl class=switch><dt>A character token, if the <a href=#current-node>current node</a> is <code><a href=#the-table-element>table</a></code>, <code><a href=#the-tbody-element>tbody</a></code>, <code><a href=#the-tfoot-element>tfoot</a></code>, <code><a href=#the-thead-element>thead</a></code>, or <code><a href=#the-tr-element>tr</a></code> element</dt> <!-- same list as foster parenting -->
<dd>

<p>Let the <dfn id=pending-table-character-tokens><var>pending table character tokens</var></dfn> be an empty list of tokens.</p>
<code><a href=#the-template-element>template</a></code>, or <code><a href=#the-html-element>html</a></code> element, pop elements from the <a href=#stack-of-open-elements>stack of open
elements</a>.</p>

<p class=note>This is the same list of elements as used in the <i><a href=#has-an-element-in-table-scope>has an element in table
scope</a></i> steps.</p>

<p class=note>The <a href=#current-node>current node</a> being an <code><a href=#the-html-element>html</a></code> element after this
process is a <a href=#fragment-case>fragment case</a>.</p>


<!-- this can only be called if the current node is one of the table model elements -->

<!--CLEANUP-->
<p>If any of the tokens in the <var><a href=#pending-table-character-tokens>pending table character tokens</a></var> list are character
tokens that are not <a href=#space-character title="space character">space characters</a>, then reprocess the
tokens that are not <a href=#space-character title="space character">space characters</a>, then this is a <a href=#parse-error>parse error</a>: reprocess the
character tokens in the <var><a href=#pending-table-character-tokens>pending table character tokens</a></var> list using the rules given in
the "anything else" entry in the "<a href=#parsing-main-intable title="insertion mode: in table">in table</a>"
insertion mode.</p>
13 index
</script><body onload=init()>
<header class="head with-buttons" id=head><p><a href=//www.whatwg.org/ class=logo><img width=101 src=/images/logo alt=WHATWG height=101></a></p>
<hgroup><h1 class=allcaps>HTML</h1>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 8 June 2014</h2>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 9 June 2014</h2>
</hgroup><div>
<div>
<a href=//whatwg.org/html><span><strong>Multipage Version</strong> <code>whatwg.org/html</code></span></a>
from the following list:</p>

<dl class=switch><dt>If <a href=#foster-parent title="foster parent">foster parenting</a> is enabled and <var title="">target</var> is a <code><a href=#the-table-element>table</a></code>, <code><a href=#the-tbody-element>tbody</a></code>, <code><a href=#the-tfoot-element>tfoot</a></code>,
<code><a href=#the-thead-element>thead</a></code>, or <code><a href=#the-tr-element>tr</a></code> element</dt>
<code><a href=#the-thead-element>thead</a></code>, or <code><a href=#the-tr-element>tr</a></code> element</dt> <!-- same list as handling of characters
in "in table" mode -->

<dd>

<p>When the user agent is to apply the rules for the "<a href=#parsing-main-intable title="insertion mode: in table">in
table</a>" <a href=#insertion-mode>insertion mode</a>, the user agent must handle the token as follows:</p>

<dl class=switch><dt>A character token, if the <a href=#current-node>current node</a> is <code><a href=#the-table-element>table</a></code>, <code><a href=#the-tbody-element>tbody</a></code>, <code><a href=#the-tfoot-element>tfoot</a></code>, <code><a href=#the-thead-element>thead</a></code>, or <code><a href=#the-tr-element>tr</a></code> element</dt>
<dl class=switch><dt>A character token, if the <a href=#current-node>current node</a> is <code><a href=#the-table-element>table</a></code>, <code><a href=#the-tbody-element>tbody</a></code>, <code><a href=#the-tfoot-element>tfoot</a></code>, <code><a href=#the-thead-element>thead</a></code>, or <code><a href=#the-tr-element>tr</a></code> element</dt> <!-- same list as foster parenting -->
<dd>

<p>Let the <dfn id=pending-table-character-tokens><var>pending table character tokens</var></dfn> be an empty list of tokens.</p>
<code><a href=#the-template-element>template</a></code>, or <code><a href=#the-html-element>html</a></code> element, pop elements from the <a href=#stack-of-open-elements>stack of open
elements</a>.</p>

<p class=note>This is the same list of elements as used in the <i><a href=#has-an-element-in-table-scope>has an element in table
scope</a></i> steps.</p>

<p class=note>The <a href=#current-node>current node</a> being an <code><a href=#the-html-element>html</a></code> element after this
process is a <a href=#fragment-case>fragment case</a>.</p>


<!-- this can only be called if the current node is one of the table model elements -->

<!--CLEANUP-->
<p>If any of the tokens in the <var><a href=#pending-table-character-tokens>pending table character tokens</a></var> list are character
tokens that are not <a href=#space-character title="space character">space characters</a>, then reprocess the
tokens that are not <a href=#space-character title="space character">space characters</a>, then this is a <a href=#parse-error>parse error</a>: reprocess the
character tokens in the <var><a href=#pending-table-character-tokens>pending table character tokens</a></var> list using the rules given in
the "anything else" entry in the "<a href=#parsing-main-intable title="insertion mode: in table">in table</a>"
insertion mode.</p>
11 source

<dt>If <span data-x="foster parent">foster parenting</span> is enabled and <var
data-x="">target</var> is a <code>table</code>, <code>tbody</code>, <code>tfoot</code>,
<code>thead</code>, or <code>tr</code> element</dt>
<code>thead</code>, or <code>tr</code> element</dt> <!-- same list as handling of characters
in "in table" mode -->

<dd>


<dl class="switch">

<dt>A character token, if the <span>current node</span> is <code>table</code>, <code>tbody</code>, <code>tfoot</code>, <code>thead</code>, or <code>tr</code> element</dt>
<dt>A character token, if the <span>current node</span> is <code>table</code>, <code>tbody</code>, <code>tfoot</code>, <code>thead</code>, or <code>tr</code> element</dt> <!-- same list as foster parenting -->
<dd>

<p>Let the <dfn><var>pending table character tokens</var></dfn> be an empty list of tokens.</p>
<code>template</code>, or <code>html</code> element, pop elements from the <span>stack of open
elements</span>.</p>

<p class="note">This is the same list of elements as used in the <i>has an element in table
scope</i> steps.</p>

<p class="note">The <span>current node</span> being an <code>html</code> element after this
process is a <span>fragment case</span>.</p>


<!-- this can only be called if the current node is one of the table model elements -->

<!--CLEANUP-->
<p>If any of the tokens in the <var>pending table character tokens</var> list are character
tokens that are not <span data-x="space character">space characters</span>, then reprocess the
tokens that are not <span data-x="space character">space characters</span>, then this is a <span>parse error</span>: reprocess the
character tokens in the <var>pending table character tokens</var> list using the rules given in
the "anything else" entry in the "<span data-x="insertion mode: in table">in table</span>"
insertion mode.</p>

0 comments on commit dab72cc

Please sign in to comment.
You can’t perform that action at this time.