Software zum Installieren eines Smart-Mirror Frameworks , zum Nutzen von hochschulrelevanten Informationen, auf einem Raspberry-Pi.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

es.typed-array.iterator.js 1.6KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. 'use strict';
  2. var global = require('../internals/global');
  3. var ArrayBufferViewCore = require('../internals/array-buffer-view-core');
  4. var ArrayIterators = require('../modules/es.array.iterator');
  5. var wellKnownSymbol = require('../internals/well-known-symbol');
  6. var ITERATOR = wellKnownSymbol('iterator');
  7. var Uint8Array = global.Uint8Array;
  8. var arrayValues = ArrayIterators.values;
  9. var arrayKeys = ArrayIterators.keys;
  10. var arrayEntries = ArrayIterators.entries;
  11. var aTypedArray = ArrayBufferViewCore.aTypedArray;
  12. var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
  13. var nativeTypedArrayIterator = Uint8Array && Uint8Array.prototype[ITERATOR];
  14. var CORRECT_ITER_NAME = !!nativeTypedArrayIterator
  15. && (nativeTypedArrayIterator.name == 'values' || nativeTypedArrayIterator.name == undefined);
  16. var typedArrayValues = function values() {
  17. return arrayValues.call(aTypedArray(this));
  18. };
  19. // `%TypedArray%.prototype.entries` method
  20. // https://tc39.es/ecma262/#sec-%typedarray%.prototype.entries
  21. exportTypedArrayMethod('entries', function entries() {
  22. return arrayEntries.call(aTypedArray(this));
  23. });
  24. // `%TypedArray%.prototype.keys` method
  25. // https://tc39.es/ecma262/#sec-%typedarray%.prototype.keys
  26. exportTypedArrayMethod('keys', function keys() {
  27. return arrayKeys.call(aTypedArray(this));
  28. });
  29. // `%TypedArray%.prototype.values` method
  30. // https://tc39.es/ecma262/#sec-%typedarray%.prototype.values
  31. exportTypedArrayMethod('values', typedArrayValues, !CORRECT_ITER_NAME);
  32. // `%TypedArray%.prototype[@@iterator]` method
  33. // https://tc39.es/ecma262/#sec-%typedarray%.prototype-@@iterator
  34. exportTypedArrayMethod(ITERATOR, typedArrayValues, !CORRECT_ITER_NAME);