unfold

Stephen Weeks sweeks@intertrust.com
Mon, 30 Jul 2001 17:41:38 -0700


> It's mostly a question of library consistency.  Since for lists, the old unfold
> can be efficiently implemented in terms of the new unfold but not vice-versa, I
> believe the new unfold should be in the LIST signature.  But I like functions
> with the same name to have the same type (e.g. List.fold, Vector.fold, ...).
> So, the question is, should the new unfold be called "unfold" or should the old
> one (I would say old).  Assuming we keep the old one as unfold, what is the
> right name for the new one.  The best I can think of is unfold'.

Arguing the other way, I can see just having the new unfold in the list
signature and ditching my usual convention, because it's really annoying to have
8 different unfolds: unfold, unfold', unfoldi, unfoldi', unfoldr, unfoldr',
unfoldri, unfoldri'.