massive update, probably broken
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-prettier / node_modules / core-js / modules / es.typed-array.last-index-of.js
1 'use strict';
2 var ArrayBufferViewCore = require('../internals/array-buffer-view-core');
3 var apply = require('../internals/function-apply');
4 var $lastIndexOf = require('../internals/array-last-index-of');
5
6 var aTypedArray = ArrayBufferViewCore.aTypedArray;
7 var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
8
9 // `%TypedArray%.prototype.lastIndexOf` method
10 // https://tc39.es/ecma262/#sec-%typedarray%.prototype.lastindexof
11 exportTypedArrayMethod('lastIndexOf', function lastIndexOf(searchElement /* , fromIndex */) {
12   var length = arguments.length;
13   return apply($lastIndexOf, aTypedArray(this), length > 1 ? [searchElement, arguments[1]] : [searchElement]);
14 });