classStaticPrivateFieldSpecGet.js 347 B

12345678910111213
  1. function _classStaticPrivateFieldSpecGet(receiver, classConstructor, descriptor) {
  2. if (receiver !== classConstructor) {
  3. throw new TypeError("Private static access of wrong provenance");
  4. }
  5. if (descriptor.get) {
  6. return descriptor.get.call(receiver);
  7. }
  8. return descriptor.value;
  9. }
  10. module.exports = _classStaticPrivateFieldSpecGet;