Ignore:
Timestamp:
01/21/25 03:08:24 (3 days ago)
Author:
stefan toskovski <stefantoska84@…>
Branches:
main
Parents:
0c6b92a
Message:

F4 Finalna Verzija

File:
1 edited

Legend:

Unmodified
Added
Removed
  • imaps-frontend/node_modules/es-abstract/2022/StringGetOwnProperty.js

    r0c6b92a r79a0317  
    22
    33var $TypeError = require('es-errors/type');
     4var isNegativeZero = require('math-intrinsics/isNegativeZero');
    45
    5 var callBound = require('call-bind/callBound');
     6var callBound = require('call-bound');
    67var $charAt = callBound('String.prototype.charAt');
    78var $stringToString = callBound('String.prototype.toString');
     
    910var CanonicalNumericIndexString = require('./CanonicalNumericIndexString');
    1011var IsIntegralNumber = require('./IsIntegralNumber');
    11 var IsPropertyKey = require('./IsPropertyKey');
    12 var Type = require('./Type');
    1312
    14 var isNegativeZero = require('is-negative-zero');
     13var isObject = require('../helpers/isObject');
     14var isPropertyKey = require('../helpers/isPropertyKey');
    1515
    1616// https://262.ecma-international.org/12.0/#sec-stringgetownproperty
     
    1818module.exports = function StringGetOwnProperty(S, P) {
    1919        var str;
    20         if (Type(S) === 'Object') {
     20        if (isObject(S)) {
    2121                try {
    2222                        str = $stringToString(S);
     
    2626                throw new $TypeError('Assertion failed: `S` must be a boxed string object');
    2727        }
    28         if (!IsPropertyKey(P)) {
    29                 throw new $TypeError('Assertion failed: IsPropertyKey(P) is not true');
     28        if (!isPropertyKey(P)) {
     29                throw new $TypeError('Assertion failed: P is not a Property Key');
    3030        }
    3131        if (typeof P !== 'string') {
Note: See TracChangeset for help on using the changeset viewer.