1 var DESCRIPTORS = require('../internals/descriptors');
2 var uncurryThis = require('../internals/function-uncurry-this');
3 var objectKeys = require('../internals/object-keys');
4 var toIndexedObject = require('../internals/to-indexed-object');
5 var $propertyIsEnumerable = require('../internals/object-property-is-enumerable').f;
7 var propertyIsEnumerable = uncurryThis($propertyIsEnumerable);
8 var push = uncurryThis([].push);
10 // `Object.{ entries, values }` methods implementation
11 var createMethod = function (TO_ENTRIES) {
12 return function (it) {
13 var O = toIndexedObject(it);
14 var keys = objectKeys(O);
15 var length = keys.length;
21 if (!DESCRIPTORS || propertyIsEnumerable(O, key)) {
22 push(result, TO_ENTRIES ? [key, O[key]] : O[key]);
30 // `Object.entries` method
31 // https://tc39.es/ecma262/#sec-object.entries
32 entries: createMethod(true),
33 // `Object.values` method
34 // https://tc39.es/ecma262/#sec-object.values
35 values: createMethod(false)