Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign up`spread` is mistakenly called "an operator" in the introduction section of ES2018 #1295
Comments
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
fkling
Aug 23, 2018
Contributor
Since this is specific to objects, maybe it should be "rest properties" and "spread properties" or "object rest" and "object spread".
Both "rest parameter" and "spread operator" are confusing at best and plain wrong at worst in the context of objects (what is a parameter in the context of objects??).
The terminology used in the spec, even in non-normative sections, should be as precise as possible IMO.
|
Since this is specific to objects, maybe it should be "rest properties" and "spread properties" or "object rest" and "object spread". Both "rest parameter" and "spread operator" are confusing at best and plain wrong at worst in the context of objects (what is a parameter in the context of objects??). The terminology used in the spec, even in non-normative sections, should be as precise as possible IMO. |
zerkms commentedAug 23, 2018
(highlight is mine) https://www.ecma-international.org/ecma-262/9.0/index.html#sec-intro
Syntactically it's not an operator, so I think the wording should be changed to "spread syntax" or something like that.