-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
third batch of suggested changes for PR #2547 #2657
Changes from all commits
c4ba786
af9e018
d59d56a
79f4d96
e477f5d
5048fd4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1789,7 +1789,7 @@ <h1> | |
<h1> | ||
Number::bitwiseNOT ( | ||
_x_: a Number, | ||
): a Number | ||
): an integral Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -1985,7 +1985,7 @@ <h1> | |
Number::leftShift ( | ||
_x_: a Number, | ||
_y_: a Number, | ||
): a Number | ||
): an integral Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -2002,7 +2002,7 @@ <h1> | |
Number::signedRightShift ( | ||
_x_: a Number, | ||
_y_: a Number, | ||
): a Number | ||
): an integral Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -2019,7 +2019,7 @@ <h1> | |
Number::unsignedRightShift ( | ||
_x_: a Number, | ||
_y_: a Number, | ||
): a Number | ||
): an integral Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -2116,7 +2116,7 @@ <h1> | |
_op_: `&`, `^`, or `|`, | ||
_x_: a Number, | ||
_y_: a Number, | ||
): a Number | ||
): an integral Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -2137,7 +2137,7 @@ <h1> | |
Number::bitwiseAND ( | ||
_x_: a Number, | ||
_y_: a Number, | ||
): a Number | ||
): an integral Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -2151,7 +2151,7 @@ <h1> | |
Number::bitwiseXOR ( | ||
_x_: a Number, | ||
_y_: a Number, | ||
): a Number | ||
): an integral Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -2165,7 +2165,7 @@ <h1> | |
Number::bitwiseOR ( | ||
_x_: a Number, | ||
_y_: a Number, | ||
): a Number | ||
): an integral Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -4234,7 +4234,8 @@ <h1> | |
1. If IsUnresolvableReference(_V_) is *true*, then | ||
1. If _V_.[[Strict]] is *true*, throw a *ReferenceError* exception. | ||
1. Let _globalObj_ be GetGlobalObject(). | ||
1. Return ? Set(_globalObj_, _V_.[[ReferencedName]], _W_, *false*). | ||
1. Perform ? Set(_globalObj_, _V_.[[ReferencedName]], _W_, *false*). | ||
1. Return ~unused~. | ||
1. If IsPropertyReference(_V_) is *true*, then | ||
1. [id="step-putvalue-toobject"] Let _baseObj_ be ? ToObject(_V_.[[Base]]). | ||
1. If IsPrivateReference(_V_) is *true*, then | ||
|
@@ -4359,7 +4360,7 @@ <h1> | |
<h1> | ||
FromPropertyDescriptor ( | ||
_Desc_: a Property Descriptor or *undefined*, | ||
): an Object | ||
): an Object or *undefined* | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -6497,7 +6498,7 @@ <h1> | |
_F_: a constructor, | ||
optional _argumentsList_: unknown, | ||
optional _newTarget_: a constructor, | ||
): a Completion Record normally containing an ECMAScript language value | ||
): a Completion Record normally containing an Object | ||
</h1> | ||
<dl class="header"> | ||
<dt>description</dt> | ||
|
@@ -10504,7 +10505,7 @@ <h1>HasSuperBinding ( ): *false*</h1> | |
</emu-clause> | ||
|
||
<emu-clause id="sec-object-environment-records-withbaseobject" type="concrete method"> | ||
<h1>WithBaseObject ( ): an ECMAScript language value</h1> | ||
<h1>WithBaseObject ( ): an Object or *undefined*</h1> | ||
<dl class="header"> | ||
<dt>for</dt> | ||
<dd>an object Environment Record _envRec_</dd> | ||
|
@@ -10674,7 +10675,7 @@ <h1>GetThisBinding ( ): a Completion Record normally containing an ECMAScript la | |
</emu-clause> | ||
|
||
<emu-clause id="sec-getsuperbase" type="concrete method"> | ||
<h1>GetSuperBase ( ): a Completion Record normally containing an ECMAScript language value</h1> | ||
<h1>GetSuperBase ( ): a Completion Record normally containing an Object, *null*, or *undefined*</h1> | ||
<dl class="header"> | ||
<dt>for</dt> | ||
<dd>a function Environment Record _envRec_</dd> | ||
|
@@ -11035,7 +11036,7 @@ <h1>WithBaseObject ( ): *undefined*</h1> | |
</emu-clause> | ||
|
||
<emu-clause id="sec-global-environment-records-getthisbinding" type="concrete method"> | ||
<h1>GetThisBinding ( ): a Completion Record normally containing an ECMAScript language value</h1> | ||
<h1>GetThisBinding ( ): a Completion Record normally containing an Object</h1> | ||
<dl class="header"> | ||
<dt>for</dt> | ||
<dd>a global Environment Record _envRec_</dd> | ||
|
@@ -11680,7 +11681,7 @@ <h1> | |
<h1> | ||
SetDefaultGlobalBindings ( | ||
_realmRec_: unknown, | ||
): a Completion Record normally containing an ECMAScript language value | ||
): a Completion Record normally containing an Object | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -12159,7 +12160,7 @@ <h1>Agents</h1> | |
</emu-note> | ||
|
||
<emu-clause id="sec-agentsignifier" type="abstract operation"> | ||
<h1>AgentSignifier ( ): an opaque value used to identify an Agent</h1> | ||
<h1>AgentSignifier ( ): an agent signifier</h1> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If we want to use this term, we should There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We've been using "an agent signifier" as a parameter-type since the memory model was added. Is there a higher bar for using it as a return-type? In the absence of a
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I am fine with using a term like "agent signifier" as long as it's obvious (it's not), self-describing (also not), or there's a An <dfn variants="agent signifiers">agent signifier</dfn> is a globally-unique opaque value used to identify an Agent. |
||
<dl class="header"> | ||
</dl> | ||
<emu-alg> | ||
|
@@ -13525,7 +13526,7 @@ <h1> | |
_key_: a property key or Private Name, | ||
_closure_: a function object, | ||
_enumerable_: a Boolean, | ||
): a Private Name or ~unused~ | ||
): a PrivateElement or ~unused~ | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -14020,7 +14021,7 @@ <h1> | |
ArraySpeciesCreate ( | ||
_originalArray_: unknown, | ||
_length_: a non-negative integer, | ||
): a Completion Record normally containing an ECMAScript language value | ||
): a Completion Record normally containing an Object | ||
</h1> | ||
<dl class="header"> | ||
<dt>description</dt> | ||
|
@@ -17344,7 +17345,7 @@ <h2>Syntax</h2> | |
</emu-note> | ||
|
||
<emu-clause id="sec-static-semantics-tv" type="sdo" oldids="sec-static-semantics-tv-and-trv"> | ||
<h1>Static Semantics: TV ( ): a String</h1> | ||
<h1>Static Semantics: TV ( ): a String or *undefined*</h1> | ||
<dl class="header"> | ||
<dt>description</dt> | ||
<dd>A template literal component is interpreted by TV as a value of the String type. TV is used to construct the indexed components of a template object (colloquially, the template values). In TV, escape sequences are replaced by the UTF-16 code unit(s) of the Unicode code point represented by the escape sequence.</dd> | ||
|
@@ -18299,29 +18300,29 @@ <h1>Runtime Semantics: Evaluation</h1> | |
<h1> | ||
Runtime Semantics: PropertyDefinitionEvaluation ( | ||
_object_: unknown, | ||
): a Completion Record normally containing a Boolean | ||
): a Completion Record normally containing ~unused~ | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
<emu-grammar>PropertyDefinitionList : PropertyDefinitionList `,` PropertyDefinition</emu-grammar> | ||
<emu-alg> | ||
1. Perform ? PropertyDefinitionEvaluation of |PropertyDefinitionList| with argument _object_. | ||
1. Return ? PropertyDefinitionEvaluation of |PropertyDefinition| with argument _object_. | ||
1. Perform ? PropertyDefinitionEvaluation of |PropertyDefinition| with argument _object_. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. These still have to return There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Not currently, and nothing as of this PR technically says that, I think? I agree it's best avoided at least until we give a definition, but I don't think it's clearly an editorial error for an AO not to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If it's not defined, it's not permitted IMO. Anyway, we shouldn't do it here or anywhere else for now. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
But agreed about not doing it for now. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I've been meaning to explicitly document at least the early exit behaviour of "return" in the algorithm conventions section. |
||
</emu-alg> | ||
<emu-grammar>PropertyDefinition : `...` AssignmentExpression</emu-grammar> | ||
<emu-alg> | ||
1. Let _exprValue_ be the result of evaluating |AssignmentExpression|. | ||
1. Let _fromValue_ be ? GetValue(_exprValue_). | ||
1. Let _excludedNames_ be a new empty List. | ||
1. Return ? CopyDataProperties(_object_, _fromValue_, _excludedNames_). | ||
1. Perform ? CopyDataProperties(_object_, _fromValue_, _excludedNames_). | ||
</emu-alg> | ||
<emu-grammar>PropertyDefinition : IdentifierReference</emu-grammar> | ||
<emu-alg> | ||
1. Let _propName_ be StringValue of |IdentifierReference|. | ||
1. Let _exprValue_ be the result of evaluating |IdentifierReference|. | ||
1. Let _propValue_ be ? GetValue(_exprValue_). | ||
1. Assert: _object_ is an ordinary, extensible object with no non-configurable properties. | ||
1. Return ! CreateDataPropertyOrThrow(_object_, _propName_, _propValue_). | ||
1. Perform ! CreateDataPropertyOrThrow(_object_, _propName_, _propValue_). | ||
</emu-alg> | ||
<emu-grammar>PropertyDefinition : PropertyName `:` AssignmentExpression</emu-grammar> | ||
<emu-alg> | ||
|
@@ -18340,14 +18341,14 @@ <h1> | |
1. Let _propValue_ be ? GetValue(_exprValueRef_). | ||
1. If _isProtoSetter_ is *true*, then | ||
1. If Type(_propValue_) is either Object or Null, then | ||
1. Return ! <emu-meta effects="user-code">_object_.[[SetPrototypeOf]]</emu-meta>(_propValue_). | ||
1. Return ~empty~. | ||
1. Perform ! <emu-meta effects="user-code">_object_.[[SetPrototypeOf]]</emu-meta>(_propValue_). | ||
1. Return ~unused~. | ||
1. Assert: _object_ is an ordinary, extensible object with no non-configurable properties. | ||
1. Return ! CreateDataPropertyOrThrow(_object_, _propKey_, _propValue_). | ||
1. Perform ! CreateDataPropertyOrThrow(_object_, _propKey_, _propValue_). | ||
</emu-alg> | ||
<emu-grammar>PropertyDefinition : MethodDefinition</emu-grammar> | ||
<emu-alg> | ||
1. Return ? MethodDefinitionEvaluation of |MethodDefinition| with arguments _object_ and *true*. | ||
1. Perform ? MethodDefinitionEvaluation of |MethodDefinition| with arguments _object_ and *true*. | ||
</emu-alg> | ||
</emu-clause> | ||
</emu-clause> | ||
|
@@ -20430,7 +20431,7 @@ <h1> | |
_lval_: an ECMAScript language value, | ||
_opText_: `**`, `*`, `/`, `%`, `+`, `-`, `<<`, `>>`, `>>>`, `&`, `^`, or `|`, | ||
_rval_: an ECMAScript language value, | ||
): a Completion Record normally containing a BigInt or a Number | ||
): a Completion Record normally containing a String, a BigInt, or a Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -20496,7 +20497,7 @@ <h1> | |
_leftOperand_: a Parse Node, | ||
_opText_: a sequence of Unicode code points, | ||
_rightOperand_: a Parse Node, | ||
): a Completion Record normally containing a BigInt or a Number | ||
): a Completion Record normally containing a String, a BigInt, or a Number | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -25705,7 +25706,7 @@ <h1> | |
_sourceText_: ECMAScript source text, | ||
_realm_: unknown, | ||
_hostDefined_: unknown, | ||
): a Script Record | ||
): a Script Record or a non-empty List of *SyntaxError* objects | ||
</h1> | ||
<dl class="header"> | ||
<dt>description</dt> | ||
|
@@ -27462,7 +27463,7 @@ <h1> | |
_sourceText_: ECMAScript source text, | ||
_realm_: unknown, | ||
_hostDefined_: unknown, | ||
): a Source Text Module Record or a List of *SyntaxError* objects | ||
): a Source Text Module Record or a non-empty List of *SyntaxError* objects | ||
</h1> | ||
<dl class="header"> | ||
<dt>description</dt> | ||
|
@@ -36016,7 +36017,7 @@ <h1> | |
RegExpBuiltinExec ( | ||
_R_: an initialized RegExp instance, | ||
_S_: a String, | ||
): a Completion Record normally containing an Object or *null* | ||
): a Completion Record normally containing an Array exotic object or *null* | ||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
@@ -39711,7 +39712,7 @@ <h1> | |
CreateMapIterator ( | ||
_map_: an ECMAScript language value, | ||
_kind_: ~key+value~, ~key~, or ~value~, | ||
): a Completion Record normally containing a generator | ||
): a Completion Record normally containing a Generator | ||
</h1> | ||
<dl class="header"> | ||
<dt>description</dt> | ||
|
@@ -40000,7 +40001,7 @@ <h1> | |
CreateSetIterator ( | ||
_set_: an ECMAScript language value, | ||
_kind_: ~key+value~ or ~value~, | ||
): a Completion Record normally containing a generator | ||
): a Completion Record normally containing a Generator | ||
</h1> | ||
<dl class="header"> | ||
<dt>description</dt> | ||
|
@@ -41525,7 +41526,7 @@ <h1> | |
RemoveWaiters ( | ||
_WL_: a WaiterList, | ||
_c_: a non-negative integer or +∞, | ||
): a List of agents | ||
): a List of agent signifiers | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
We should update the WaiterList definition to match whatever we do here. |
||
</h1> | ||
<dl class="header"> | ||
</dl> | ||
|
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.
Only if we also change
[[Construct]]
to return "a Completion Record normally containing an Object", right?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.
Yes, sorry, those should change as well.