Skip to content

Commit 8ea0018

Browse files
jgrahamAutomatedTester
authored andcommitted
Fix Respec errors
The problem seemed to be that Respec expected [[Foo]] internal methods to be associated with a WebIDL interface, which they aren't because they're in ECMAScript. The somewhat hacky workaround is to use the ECMAScript type they're defined on as the interface name like `Object.[[Put]]` in place of `[[Put]]`. This doesn't seem ideal, but it at least fixes the errors, and the intent is still understandable.
1 parent d8556ca commit 8ea0018

File tree

1 file changed

+35
-33
lines changed

1 file changed

+35
-33
lines changed

index.html

Lines changed: 35 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -362,29 +362,30 @@ <h3>Algorithms</h3>
362362
</ol>
363363

364364
<p>The result of <dfn data-lt="getting properties|getting the
365-
property">getting a property</dfn> with argument <var>name</var> is
366-
defined as being the same as the result of calling
367-
<a>Object</a>.<a>[[\GetOwnProperty]]</a>(<var>name</var>).
365+
property">getting a property</dfn> with <var>name</var>
366+
from <var>object</var> is defined as being the same as the result of
367+
calling <a>Object.[[\GetOwnProperty]]</a>(<var>name</var>) on <var>object</var>.
368368

369369
<p>The result of <dfn data-lt="getting the property with
370370
default">getting a property with default</dfn> with
371-
arguments <var>name</var> and <var>default</var> is defined as being
372-
the same as the result of calling
373-
<a>Object</a>.<a>[[\GetOwnProperty]]</a>(<var>name</var>) if that
374-
results in a value other than <code>undefined</code>
375-
and <var>default</var> otherwise.
371+
arguments <var>name</var> and <var>default</var>
372+
from <var>object</var> is defined as being the same as the result of
373+
calling
374+
<a>Object.[[\GetOwnProperty]]</a>(<var>name</var>)
375+
on <var>object</var> if that results in a value other
376+
than <code>undefined</code> and <var>default</var> otherwise.
376377

377378
<p><dfn data-lt='set a property'>Setting a property</dfn> with
378-
arguments <var>name</var> and <var>value</var> is defined as being
379-
the same as calling
380-
<a>Object</a>.<a>[[\Put]]</a>(<var>name</var>, <var>value</var>).
379+
arguments <var>name</var> and <var>value</var> on <var>ovject</var>
380+
is defined as being the same as calling
381+
<a>Object.[[\Put]]</a>(<var>name</var>, <var>value</var>) on <var>object</var>.
381382

382383
<p>The result of <dfn>JSON serialization</dfn> with <var>object</var>
383384
of type JSON <a>Object</a> is defined as the result of
384-
calling <code>JSON.</code><a>[[\Stringify]]</a>(<var>object</var>).
385+
calling <a>stringify</a>(<var>object</var>).
385386

386387
<p>The result of <dfn data-lt='parsing as json'>JSON deserialization</dfn> with <var>text</var> is defined as
387-
the result of calling <code>JSON.</code><a>[[\Parse]]</a>(<var>text</var>).
388+
the result of calling <a>parse</a>(<var>text</var>).
388389
</section> <!-- /Algorithms -->
389390

390391

@@ -4168,8 +4169,8 @@ <h2>Elements</h2>
41684169
<dd>"<code>nearest</code>"
41694170
</dl>
41704171

4171-
<li><p>On the <var><a>element</a></var>,
4172-
<a>Call</a>(<a>scrollIntoView</a>, <var>options</var>).
4172+
<li><p>Run <a>Function.[[\Call]]</a>(<a>scrollIntoView</a>, <var>options</var>)
4173+
with <var>element</var> as the this value.
41734174
</ol>
41744175

41754176
<p><dfn>Editable</dfn> <a>elements</a>
@@ -5280,7 +5281,7 @@ <h4><dfn>Get Element Property</dfn></h4>
52805281
with <a>url variable</a> <var>element id</var>.
52815282

52825283
<li><p>Let <var>property</var> be the result of calling
5283-
the <var>element</var>.<a>[[\GetProperty]]</a>(<var>name</var>).
5284+
the <a>Object.[[\GetProperty]]</a>(<var>name</var>) on <var>element</var>.
52845285

52855286
<li><p>Let <var>result</var> be the value of
52865287
<var>property</var> if not <a>undefined</a>, or <a><code>null</code></a>.
@@ -5384,9 +5385,10 @@ <h4><dfn>Get Element Text</dfn></h4>
53845385
with <a>url variable</a> <var>element id</var>.
53855386

53865387
<li><p>Let <var>rendered text</var> be the result of performing
5387-
implementation-specific steps whose result is exactly the same as the
5388-
result of a <a>Call</a>(<a><code>bot.dom.getVisibleText</code></a>,
5389-
<a><code>null</code></a>, <var>element</var>).
5388+
implementation-specific steps whose result is exactly the same as
5389+
the result of
5390+
a <a>Function.[[\Call]]</a>(<a><code>null</code></a>, <var>element</var>)
5391+
with <a><code>bot.dom.getVisibleText</code></a> as the this value.
53905392

53915393
<li><p>Return <a>success</a> with data <var>rendered text</var>.
53925394
</ol>
@@ -6475,7 +6477,8 @@ <h3>Executing Script</h3>
64756477
<dt>has an <a>own property</a> named "<code>toJSON</code>" that is
64766478
a <a>Function</a>
64776479
<dd>Return <a>success</a> with the value returned by
6478-
<a>Call</a>(<code>toJSON</code>).
6480+
<a>Function.[[\Call]]</a>(<code>toJSON</code>) with <var>value</var>
6481+
as the this value.
64796482

64806483
<dt>Otherwise</dt>
64816484
<dd>
@@ -6617,9 +6620,8 @@ <h3>Executing Script</h3>
66176620
</dl>
66186621

66196622
<li><p>Let <var>completion</var> be
6620-
<a>Call</a>(<var>function</var>,
6621-
<var>window</var>,
6622-
<var>parameters</var>).
6623+
<a>Function.[[\Call]]</a>(<var>window</var>,
6624+
<var>parameters</var>) with <var>function</var> as the this value.
66236625

66246626
<li><p><a>Clean up after running a callback</a>
66256627
with <var>environment settings</var>.
@@ -10475,8 +10477,8 @@ <h2>Element displayedness</h2>
1047510477
is a boolean state where <code>true</code> signifies that the element is displayed
1047610478
and <code>false</code> signifies that the element is not displayed.
1047710479
To compute the state on <var>element</var>,
10478-
invoke the <a>Call</a>(<a><code>bot.dom.isShown</code></a>,
10479-
<a><code>null</code></a>, <var>element</var>).
10480+
invoke the <a>Function.[[\Call]]</a>(<a><code>null</code></a>, <var>element</var>),
10481+
with <a><code>bot.dom.isShown</code></a> as the this value.
1048010482
If doing so does not produce an error,
1048110483
return the return value from this function call.
1048210484
Otherwise return an <a>error</a> with <a>error code</a> <a>unknown error</a>.
@@ -10709,14 +10711,14 @@ <h2>Index</h2>
1070910711

1071010712
<dd>This specification also presumes that you are able to call
1071110713
some of the <dfn data-lt="internal method"><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.6.2>internal methods</a></dfn>
10712-
from the ECMAScript Language Specification:
10714+
from the ECMAScript Language Specification [[ECMAScript]]:
1071310715
<ul>
10714-
<!-- Call --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-13.2.1>Call</a></dfn>
10715-
<!-- Class --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.6.2>[[\Class]]</a></dfn>
10716-
<!-- GetOwnProperty --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.12.1>[[\GetOwnProperty]]</a></dfn>
10717-
<!-- GetProperty --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.12.2>[[\GetProperty]]</a></dfn>
10716+
<!-- Call --> <li><dfn data-dfn-for="Function"><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-13.2.1>[[\Call]]</a></dfn>
10717+
<!-- Class --> <li><dfn data-dfn-for="Object"><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.6.2>[[\Class]]</a></dfn>
10718+
<!-- GetOwnProperty --> <li><dfn data-dfn-for="Object"><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.12.1>[[\GetOwnProperty]]</a></dfn>
10719+
<!-- GetProperty --> <li><dfn data-dfn-for="Object"><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.12.2>[[\GetProperty]]</a></dfn>
1071810720
<!-- Index of --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-15.5.4.7>Index of</a></dfn>
10719-
<!-- Put --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.12.5>[[\Put]]</a></dfn>
10721+
<!-- Put --> <li><dfn data-dfn-for="Object"><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-8.12.5>[[\Put]]</a></dfn>
1072010722
<!-- Substring --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-15.5.4.15>Substring</a></dfn>
1072110723
</ul>
1072210724

@@ -10731,9 +10733,9 @@ <h2>Index</h2>
1073110733
<!-- null --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-4.3.11><code>null</code></a></dfn>
1073210734
<!-- Number --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-4.3.19>Number</a></dfn>
1073310735
<!-- Object --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-4.2.1>Object</a></dfn>
10734-
<!-- Parse --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-15.12.2>[[\Parse]]</a></dfn>
10736+
<!-- parse --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-15.12.2>parse</a></dfn>
1073510737
<!-- String --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-4.3.18>String</a></dfn>
10736-
<!-- Stringify --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-15.12.3>[[\Stringify]]</a></dfn>
10738+
<!-- stringify --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-15.12.3>stringify</a></dfn>
1073710739
<!-- ToInteger --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/6.0/#sec-tointeger>ToInteger</a></dfn>
1073810740
<!-- undefined --> <li><dfn><a href=https://www.ecma-international.org/ecma-262/5.1/#sec-4.3.9>Undefined</a></dfn>
1073910741
</ul>

0 commit comments

Comments
 (0)