File tree 1 file changed +5
-5
lines changed
1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ function create() {
14
14
}
15
15
exports . create = create ;
16
16
17
- // show the most idle item
17
+ // Show the most idle item.
18
18
function peek ( list ) {
19
19
if ( list . _idlePrev === list ) return null ;
20
20
return list . _idlePrev ;
@@ -31,7 +31,7 @@ function shift(list) {
31
31
exports . shift = shift ;
32
32
33
33
34
- // remove a item from its list
34
+ // Remove an item from its list.
35
35
function remove ( item ) {
36
36
if ( item . _idleNext ) {
37
37
item . _idleNext . _idlePrev = item . _idlePrev ;
@@ -47,18 +47,18 @@ function remove(item) {
47
47
exports . remove = remove ;
48
48
49
49
50
- // remove a item from its list and place at the end.
50
+ // Remove an item from its list and place at the end.
51
51
function append ( list , item ) {
52
52
if ( item . _idleNext || item . _idlePrev ) {
53
53
remove ( item ) ;
54
54
}
55
55
56
- // items are linked with _idleNext -> (older) and _idlePrev -> (newer)
56
+ // Items are linked with _idleNext -> (older) and _idlePrev -> (newer).
57
57
// Note: This linkage (next being older) may seem counter-intuitive at first.
58
58
item . _idleNext = list . _idleNext ;
59
59
item . _idlePrev = list ;
60
60
61
- // the list _idleNext points to tail (newest) and _idlePrev to head (oldest)
61
+ // The list _idleNext points to tail (newest) and _idlePrev to head (oldest).
62
62
list . _idleNext . _idlePrev = item ;
63
63
list . _idleNext = item ;
64
64
}
You can’t perform that action at this time.
0 commit comments