1 // Copyright (C) 2020 Rick Waldron. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
4 esid: sec-%typedarray%.prototype.at
6 Property type and descriptor.
8 %TypedArray%.prototype.at( index )
10 Let relativeIndex be ? ToInteger(index).
12 includes: [testTypedArray.js]
13 features: [TypedArray, TypedArray.prototype.at]
16 typeof TypedArray.prototype.at,
18 'The value of `typeof TypedArray.prototype.at` is "function"'
21 testWithTypedArrayConstructors(TA => {
22 assert.sameValue(typeof TA.prototype.at, 'function', 'The value of `typeof TA.prototype.at` is "function"');
23 let a = new TA([0,1,2,3]);
25 assert.throws(TypeError, () => {
27 }, '`a.at(Symbol())` throws TypeError');