mirror of
https://github.com/musix-org/musix-oss
synced 2024-12-23 22:33:17 +00:00
18 lines
744 B
JavaScript
18 lines
744 B
JavaScript
|
'use strict';
|
||
|
var $ = require('../internals/export');
|
||
|
var DESCRIPTORS = require('../internals/descriptors');
|
||
|
var FORCED = require('../internals/object-prototype-accessors-forced');
|
||
|
var toObject = require('../internals/to-object');
|
||
|
var aFunction = require('../internals/a-function');
|
||
|
var definePropertyModule = require('../internals/object-define-property');
|
||
|
|
||
|
// `Object.prototype.__defineGetter__` method
|
||
|
// https://tc39.github.io/ecma262/#sec-object.prototype.__defineGetter__
|
||
|
if (DESCRIPTORS) {
|
||
|
$({ target: 'Object', proto: true, forced: FORCED }, {
|
||
|
__defineGetter__: function __defineGetter__(P, getter) {
|
||
|
definePropertyModule.f(toObject(this), P, { get: aFunction(getter), enumerable: true, configurable: true });
|
||
|
}
|
||
|
});
|
||
|
}
|