Comments (9)
You could use the same language as in 9.4.4 Arguments Exotic Objects, for example:
Return the result of calling the default ordinary object [[SetPrototypeOf]] internal method (9.1.2) on O passing V as the argument.
[[Get]], [[Set]] and [[Delete]] for arguments objects use this wording to call the ordinary internal methods.
from ecma262.
I guess that covers it; thanks!
from ecma262.
Is there a reason ECMAScript uses both patterns?
from ecma262.
@annevk which patterns are you referring to?
from ecma262.
What @anba mentioned and using OrdinaryInternalMethod abstract operations.
from ecma262.
Also, if I say use "default ordinary object [[Get]] internal method", does that mean the [[GetOwnProperty]] call it does (and similar ones) are the normal non-overridden variants as well?
from ecma262.
@annevk
Choice of how to do this is mostly a judgement call by the editor. delegating to OrdinaryX abstraction operation adds a level of indirection that make the normal case harder to read/understand. Using ""default ordinary object..." (and note a section reference is always included) only adds complexity at the "call site".
If you say "call the default ordinary object [[Get]] internal method" (and you need to include a section reference) you mean exactly and only that. If you say "call the [[GetOwnProperty internal method of obj" (or just say obj.[GetOwnProperty] ) you are going throw the meta-level dynamic dispatch to the specific [[GetOwnPrperty]] associated with obj.
from ecma262.
It's still not clear that if you say "call the default ordinary object [[Get]] internal method" that means that the internal methods that that algorithm invokes, are also the default ordinary ones. At least not to me.
from ecma262.
@annevk It is just referring to the internal methods specified in 9.1.
Arguably, the word "default" is redundant as any object that does not use the definitions in 9.1 is not an "ordinary object".
from ecma262.
Related Issues (20)
- Editorial: Defining each kind of built-in exotic in one place HOT 1
- update the colophon to mention new fonts
- update the description of enum presentation in 6.2.1
- Boolean interpretation to and from string HOT 3
- Small change feature request. HOT 7
- Cover grammar application should be more discoverable HOT 2
- [spam]
- Generator.prototype is not defined HOT 9
- Inconsistent "well known symbol" vs "well-known symbol" in Symbol.asyncIterator HOT 1
- Missing period in AsyncFunction.prototype.constructor section
- %GeneratorFunction.prototype.prototype.next% is not defined HOT 2
- "this value" and "NewTarget" no longer defined in Built-in Function Objects HOT 1
- `%TypedArray%.prototype.slice` does not completely account for the original TA's size changing HOT 3
- Encoding and decoding issues of `<script>` characters using decodeURIComponent and encodeURIComponent HOT 6
- Object invariants disallow changing non-configurable but writable data property's value HOT 7
- [spam]
- "substring of" used with potentially out of bounds end in String.prototype.split()
- [spam]
- Missing String Row in ToObject Conversions Table on ECMAScript Specification 2023 PDF HOT 4
- Suggestion: `[no ASI if lookahead ...]` constraint instead of SS rules for OptionalChain
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ecma262.