
18 Aug
2009
18 Aug
'09
12:51 p.m.
2009/8/18 Dusan Kolar
Dlists maybe good it all the app is written using them. Probably not good idea to switch to them in the middle of project...
I have a different criterion for DLists. I think they are best to use in small scopes (I think the same of monads), as opposed to interfacing between different parts of a project. A DList is well-suited when you are *outputting* a list using appends; i.e. just concatenating stuff together, but not looking at the heads or iterating over the lists. The DList Quicksort is a perfect example. It also makes a good monoid for Writer. toList it after you're done generating; this is an efficient operation. Luke