[Haskell-cafe] IO Help
Daniel Fischer
daniel.is.fischer at web.de
Thu May 8 09:19:53 EDT 2008
Am Donnerstag, 8. Mai 2008 14:59 schrieb Mark Wallsgrove:
> Thank you very much for your fast response!
>
> Ok, that is now changed, but everything else in my program is expecting
> Catalogue without IO. Is there a way to change IO Catalogue into Catalogue?
>
Not a recommendable way. But there's no need to, your programme will probably
look like
main = do
args <- getArgs
let realArgs = parseArgs args
catalogue <- loadData
doSomething realArgs catalogue
and doSomething might e.g. construct an updated catalogue and write it to a
file.
More information about the Haskell-Cafe
mailing list