yield and await are permitted as
let
await 0;
yield or await.
\ The result of evaluating an
In yield may be used as an identifier. Evaluating the yield as if it was an
When processing an instance of the production
the interpretation of
this KeywordSee
false, return true, return An
Array elements may be elided at the beginning, middle or end of the element list. Whenever a comma in the element list is not preceded by an
With parameters array and nextIndex.
An object initializer is an expression describing the initialization of an Object, written in a form resembling a literal. It is a list of zero or more pairs of property keys and associated values, enclosed in curly brackets. The values need not be literals; they are evaluated each time the object initializer is evaluated.
In certain contexts,
In addition to describing an actual object initializer the
This production exists so that
With parameters object and enumerable.
An alternative semantics for this production is given in
See
See
See
See
See
See
The abstract operation IsValidRegularExpressionLiteral takes argument literal. It determines if its argument is a valid regular expression literal. It performs the following steps when called:
g, i, m, s, u, or y, or if it contains the same code point more than once, return u, let u be With parameter raw.
The abstract operation GetTemplateObject takes argument templateLiteral (a
The creation of a template object cannot result in an
Each
Future editions of this specification may define additional non-enumerable properties of template objects.
The string conversion semantics applied to the String.prototype.concat rather than the + operator.
The string conversion semantics applied to the String.prototype.concat rather than the + operator.
The string conversion semantics applied to the String.prototype.concat rather than the + operator.
This algorithm does not apply delete and typeof may be applied to parenthesized expressions.
When processing an instance of the production
the interpretation of
This production exists in order to prevent automatic semicolon insertion rules (
a?.b
`c`
so that it would be interpreted as two valid statements. The purpose is to maintain consistency with similar code without optional chaining:
a.b
`c`
which is a valid statement and where automatic semicolon insertion does not apply.
Properties are accessed by name, using either the dot notation:
or the bracket notation:
The dot notation is explained by the following syntactic conversion:
is identical in its behaviour to
and similarly
is identical in its behaviour to
where <identifier-name-string> is the result of evaluating
The abstract operation EvaluatePropertyAccessWithExpressionKey takes arguments baseValue (an
The abstract operation EvaluatePropertyAccessWithIdentifierKey takes arguments baseValue (an
new OperatorThe abstract operation EvaluateNew takes arguments constructExpr and arguments. It performs the following steps when called:
A
The abstract operation EvaluateCall takes arguments func (an
super KeywordThe abstract operation GetSuperConstructor takes no arguments. It performs the following steps when called:
The abstract operation MakeSuperPropertyReference takes arguments actualThis, propertyKey, and strict. It performs the following steps when called:
The evaluation of an argument list produces a
?..With parameters baseValue and baseReference.
A tagged template is a function call where the arguments of the call are derived from a
The import.meta.
The implementation of HostGetImportMetaProperties must conform to the following requirements:
The default implementation of HostGetImportMetaProperties is to return a new empty
The import.meta.
Most hosts will be able to simply define
The implementation of HostFinalizeImportMeta must conform to the following requirements:
The default implementation of HostFinalizeImportMeta is to return
delete OperatorIt is a Syntax Error if the derived
and
The last rule means that expressions such as delete (((foo))) produce early errors because of recursive application of the first rule.
When a delete operator occurs within delete operator occurs within
The object that may be created in step
void Operatortypeof Operator| Type of val | Result |
|---|---|
| Undefined |
|
| Null |
|
| Boolean |
|
| Number |
|
| String |
|
| Symbol |
|
| BigInt |
|
| Object (does not implement [[Call]]) |
|
| Object (implements [[Call]]) |
|
An additional entry related to [[IsHTMLDDA]] Internal Slot can be found in
+ OperatorThe unary + operator converts its operand to Number type.
- OperatorThe unary - operator converts its operand to Number type and then negates it. Negating
~ )! )* operator performs multiplication, producing the product of its operands./ operator performs division, producing the quotient of its operands.% operator yields the remainder of its operands from an implied division.+ )The addition operator either performs string concatenation or numeric addition.
- )The - operator performs subtraction, producing the difference of its operands.
<< )Performs a bitwise left shift operation on the left operand by the amount specified by the right operand.
<<, >> )Performs a sign-filling bitwise right shift operation on the left operand by the amount specified by the right operand.
>>, >>> )Performs a zero-filling bitwise right shift operation on the left operand by the amount specified by the right operand.
>>>, The result of evaluating a relational operator is always of type Boolean, reflecting whether the relationship named by the operator holds between its two operands.
The [In] grammar parameter is needed to avoid confusing the in operator in a relational expression with the in operator in a for statement.
The abstract operation InstanceofOperator takes arguments V (an
Steps instanceof operator semantics. If an object does not define or inherit instanceof semantics.
The result of evaluating an equality operator is always of type Boolean, reflecting whether the relationship named by the operator holds between its two operands.
Given the above definition of equality:
`${a}` == `${b}`.
+a == +b.
!a == !b.
The equality operators maintain the following invariants:
A != B is equivalent to !(A == B).
A == B is equivalent to B == A, except in the order of evaluation of A and B.
The equality operator is not always transitive. For example, there might be two distinct String objects, each representing the same String value; each String object would be considered equal to the String value by the == operator, but the two String objects would not be equal to each other. For example:
new String("a") == "a" and "a" == new String("a") are both new String("a") == new String("a") is Comparison of Strings uses a simple equality test on sequences of code unit values. There is no attempt to use the more complex, semantically oriented definitions of character or string equality and collating order defined in the Unicode specification. Therefore Strings values that are canonically equal according to the Unicode standard could test as unequal. In effect this algorithm assumes that both Strings are already in normalized form.
The value produced by a && or || operator is not necessarily of type Boolean. The value produced will always be the value of one of the two operand expressions.
? : )The grammar for a
If
If
| assignmentOpText | opText |
|---|---|
**= | ** |
*= | * |
/= | / |
%= | % |
+= | + |
-= | - |
<<= | << |
>>= | >> |
>>>= | >>> |
&= | & |
^= | ^ |
|= | | |
When this expression occurs within
The abstract operation ApplyStringOrNumericBinaryOperator takes arguments lval (an
+, then| opText | operation |
|---|---|
** | T::exponentiate |
* | T::multiply |
/ | T::divide |
% | T::remainder |
+ | T::add |
- | T::subtract |
<< | T::leftShift |
>> | T::signedRightShift |
>>> | T::unsignedRightShift |
& | T::bitwiseAND |
^ | T::bitwiseXOR |
| | T::bitwiseOR |
No hint is provided in the calls to
Step
The abstract operation EvaluateStringOrNumericBinaryExpression takes arguments leftOperand (a
In certain circumstances when processing an instance of the production
the interpretation of
If
If
With parameter value.
With parameter value.
With parameters value and excludedNames.
With parameter iteratorRecord.
Left to right evaluation order is maintained by evaluating a
With parameters value and propertyName.
, )