add Traversable generalizations of mapAccumL and mapAccumR (#2461)