Skip to content

Commit

Permalink
Editorial: Fix minor typos
Browse files Browse the repository at this point in the history
... in "Block-Level Function Declarations Web Legacy Compatibility Semantics"
  • Loading branch information
jmdyck authored and ljharb committed Sep 14, 2021
1 parent 5e42158 commit b3e6dfe
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions spec.html
Original file line number Diff line number Diff line change
Expand Up @@ -46934,16 +46934,16 @@ <h1>Labelled Function Declarations</h1>

<emu-annex id="sec-block-level-function-declarations-web-legacy-compatibility-semantics">
<h1>Block-Level Function Declarations Web Legacy Compatibility Semantics</h1>
<p>Prior to ECMAScript 2015, the ECMAScript specification did not define the occurrence of a |FunctionDeclaration| as an element of a |Block| statement's |StatementList|. However, support for that form of |FunctionDeclaration| was an allowable extension and most browser-hosted ECMAScript implementations permitted them. Unfortunately, the semantics of such declarations differ among those implementations. Because of these semantic differences, existing web ECMAScript code that uses |Block| level function declarations is only portable among browser implementation if the usage only depends upon the semantic intersection of all of the browser implementations for such declarations. The following are the use cases that fall within that intersection semantics:</p>
<p>Prior to ECMAScript 2015, the ECMAScript specification did not define the occurrence of a |FunctionDeclaration| as an element of a |Block| statement's |StatementList|. However, support for that form of |FunctionDeclaration| was an allowable extension and most browser-hosted ECMAScript implementations permitted them. Unfortunately, the semantics of such declarations differ among those implementations. Because of these semantic differences, existing web ECMAScript code that uses |Block| level function declarations is only portable among browser implementations if the usage only depends upon the semantic intersection of all of the browser implementations for such declarations. The following are the use cases that fall within that intersection semantics:</p>
<ol>
<li>
<p>A function is declared and only referenced within a single block</p>
<p>A function is declared and only referenced within a single block.</p>
<ul>
<li>
One or more |FunctionDeclaration|s whose |BindingIdentifier| is the name _f_ occur within the function code of an enclosing function _g_ and that declaration is nested within a |Block|.
</li>
<li>
No other declaration of _f_ that is not a `var` declaration occurs within the function code of _g_
No other declaration of _f_ that is not a `var` declaration occurs within the function code of _g_.
</li>
<li>
All occurrences of _f_ as an |IdentifierReference| are within the |StatementList| of the |Block| containing the declaration of _f_.
Expand All @@ -46957,7 +46957,7 @@ <h1>Block-Level Function Declarations Web Legacy Compatibility Semantics</h1>
One or more |FunctionDeclaration|s whose |BindingIdentifier| is the name _f_ occur within the function code of an enclosing function _g_ and that declaration is nested within a |Block|.
</li>
<li>
No other declaration of _f_ that is not a `var` declaration occurs within the function code of _g_
No other declaration of _f_ that is not a `var` declaration occurs within the function code of _g_.
</li>
<li>
There may be occurrences of _f_ as an |IdentifierReference| within the |StatementList| of the |Block| containing the declaration of _f_.
Expand All @@ -46977,7 +46977,7 @@ <h1>Block-Level Function Declarations Web Legacy Compatibility Semantics</h1>
One or more |FunctionDeclaration| whose |BindingIdentifier| is the name _f_ occur within the function code of an enclosing function _g_ and that declaration is nested within a |Block|.
</li>
<li>
No other declaration of _f_ that is not a `var` declaration occurs within the function code of _g_
No other declaration of _f_ that is not a `var` declaration occurs within the function code of _g_.
</li>
<li>
There may be occurrences of _f_ as an |IdentifierReference| within the |StatementList| of the |Block| containing the declaration of _f_.
Expand Down

0 comments on commit b3e6dfe

Please sign in to comment.