[Haskell-cafe] Library design question

Andre Nathan andre at digirati.com.br
Thu Sep 18 17:10:52 EDT 2008

On Thu, 2008-09-18 at 21:13 +0200, minh thu wrote:
> If you need the one inside the State monad, you can reuse the new
> version of addVertex.

You mean making the graph creation functions (which will call
addVertex/Edge) use the State monad instead? Interesting idea... what I
really wanted was to hide from the user how the graph library is
implemented, so he wouldn't need to know about the state monad to use
the library, but maybe I should keep these basic functions pure and let
the user decide. I'll think about it :)


More information about the Haskell-Cafe mailing list