File tree Expand file tree Collapse file tree 1 file changed +6
-14
lines changed
Expand file tree Collapse file tree 1 file changed +6
-14
lines changed Original file line number Diff line number Diff line change 88
99 // https://github.com/nodejs/node/issues/21219
1010 // Adds Atomics.notify and warns on first usage of Atomics.wake
11+ // https://github.com/v8/v8/commit/c79206b363 adds Atomics.notify so
12+ // now we alias Atomics.wake to notify so that we can remove it
13+ // semver major without worrying about V8.
1114
12- const AtomicsWake = global . Atomics . wake ;
15+ const AtomicsNotify = global . Atomics . notify ;
1316 const ReflectApply = global . Reflect . apply ;
1417
15- // wrap for function.name
16- function notify ( ...args ) {
17- return ReflectApply ( AtomicsWake , this , args ) ;
18- }
19-
2018 const warning = 'Atomics.wake will be removed in a future version, ' +
2119 'use Atomics.notify instead.' ;
2220
2321 let wakeWarned = false ;
24- function wake ( ... args ) {
22+ function wake ( typedArray , index , count ) {
2523 if ( ! wakeWarned ) {
2624 wakeWarned = true ;
2725
3230 }
3331 }
3432
35- return ReflectApply ( AtomicsWake , this , args ) ;
33+ return ReflectApply ( AtomicsNotify , this , arguments ) ;
3634 }
3735
3836 global . Object . defineProperties ( global . Atomics , {
39- notify : {
40- value : notify ,
41- writable : true ,
42- enumerable : false ,
43- configurable : true ,
44- } ,
4537 wake : {
4638 value : wake ,
4739 writable : true ,
You can’t perform that action at this time.
0 commit comments