Re:Design patterns explained in Javascript
by eru on Thursday July 14, 2011 @03:58PM
(#2764779)
You are one the wrong track. You'll be surprised. Look up algebraic data structures and zippers. The partial derivative of an algebraic data structure is its zipper.
See e.g. http://www.haskell.org/haskellwiki/Zipper
And, yes, automatic derivation of zippers is mind blowing, when you encouter it for the first time.