Skip to content

Commit

Permalink
feat: add Array#at close #1139 (#1146)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jack-Works authored and naugtur committed May 16, 2022
1 parent e880735 commit 046dfcd
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions packages/ses/src/whitelist.js
Original file line number Diff line number Diff line change
Expand Up @@ -421,6 +421,7 @@ export const whitelist = {
getOwnPropertyNames: fn,
getOwnPropertySymbols: fn,
getPrototypeOf: fn,
hasOwn: fn,
is: fn,
isExtensible: fn,
isFrozen: fn,
Expand All @@ -431,8 +432,6 @@ export const whitelist = {
seal: fn,
setPrototypeOf: fn,
values: fn,
// See https://github.com/tc39/proposal-accessible-object-hasownproperty
hasOwn: fn,
},

'%ObjectPrototype%': {
Expand Down Expand Up @@ -727,6 +726,7 @@ export const whitelist = {
'%StringPrototype%': {
// Properties of the String Prototype Object
length: 'number',
at: fn,
charAt: fn,
charCodeAt: fn,
codePointAt: fn,
Expand Down Expand Up @@ -780,10 +780,6 @@ export const whitelist = {
trimRight: fn,
// See https://github.com/Moddable-OpenSource/moddable/issues/523
compare: false,

// Stage 3:
// https://tc39.es/proposal-relative-indexing-method/
at: fn,
},

'%StringIteratorPrototype%': {
Expand Down Expand Up @@ -880,6 +876,7 @@ export const whitelist = {

'%ArrayPrototype%': {
// Properties of the Array Prototype Object
at: fn,
length: 'number',
concat: fn,
constructor: 'Array',
Expand Down Expand Up @@ -933,9 +930,6 @@ export const whitelist = {
findLast: 'boolean',
findLastIndex: 'boolean',
},
// Failed tc39 proposal
// Seen on FF Nightly 88.0a1
at: false,
// See https://github.com/tc39/proposal-array-find-from-last
findLast: fn,
findLastIndex: fn,
Expand All @@ -960,6 +954,7 @@ export const whitelist = {
},

'%TypedArrayPrototype%': {
at: fn,
buffer: getter,
byteLength: getter,
byteOffset: getter,
Expand Down Expand Up @@ -992,9 +987,6 @@ export const whitelist = {
values: fn,
'@@iterator': fn,
'@@toStringTag': getter,
// Failed tc39 proposal
// Seen on FF Nightly 88.0a1
at: false,
// See https://github.com/tc39/proposal-array-find-from-last
findLast: fn,
findLastIndex: fn,
Expand Down

0 comments on commit 046dfcd

Please sign in to comment.