(current, new *DLNode)
| 78 | } |
| 79 | |
| 80 | func (this *LRUCache) pushAfter(current, new *DLNode) { |
| 81 | next := current.next |
| 82 | new.prev, new.next = current, next |
| 83 | current.next, next.prev = new, new |
| 84 | } |
| 85 | |
| 86 | func (this *LRUCache) delete(curr *DLNode) { |
| 87 | prev, next := curr.prev, curr.next |