1234567891011121314151617181920212223242526272829 |
- 'use strict';
- var GetIntrinsic = require('get-intrinsic');
- var $TypeError = GetIntrinsic('%TypeError%');
- var IsPropertyKey = require('./IsPropertyKey');
- var ToObject = require('./ToObject');
- module.exports = function GetV(V, P) {
-
- if (!IsPropertyKey(P)) {
- throw new $TypeError('Assertion failed: IsPropertyKey(P) is not true');
- }
-
- var O = ToObject(V);
-
- return O[P];
- };
|