fromList xs is a
DList representing the list
xs.
fromList obeys the laws:
toList . fromList = id
fromList . toList = id
This function is implemented with
++. Repeated uses of
fromList are just as inefficient as repeated uses of
++. If you find yourself doing some form of the following
(possibly indirectly), you may not be taking advantage of the
DList representation and library:
fromList . f . toList
More likely, you will convert from a list, perform some operation on
the
DList, and convert back to a list:
toList . g . fromList