4 ms·
Come to think of it, Deutsch, Schorr and Waite’s algorithm for traversing a data structure by reversing pointers within it can also be viewed as a form of a zip
by i_don_t_know 4y ago
Come to think of it, Deutsch, Schorr and Waite’s algorithm for traversing a data structure by reversing pointers within it can also be viewed as a form of a zipper. Except that DSW’s algorithm predates the zipper.
DSW’s algorithm is used in the mark phase of garbage collection. It traverses and marks all reachable data in constant space.
https://inst.eecs.berkeley.edu/~cs61bl/r//cur/graphs/garbage-collection-no-fringe.html?topic=lab24.topic&step=8&course= https://inst.eecs.berkeley.edu/~cs61bl/r//cur/graphs/garbage...
- taeric 4y agoThis feels like the other end of a debate. Moving from immutable structures to hyper optimized traversal of mutable data. :) Does remind me of threaded trees. Stackless traversal is a fun topic.