[Haskell-cafe] help with some code

gbwey9 gbwey9 at gmail.com
Fri Jul 11 15:01:14 UTC 2014

Hi Cafe,

I've got some code where a user can provide a filter to subscribe to a
particular type of event.  The events come in as xml and are parsed using
the toEvent method.
The code works fine but is repetitive since each event record potentially
has the information needed to parse the xml using the field names and

So is there a way to get rid of the repetition and streamline the code?
Should I be using TH or lenses or something else entirely?

Here is the paste.

Thanks for any pointers!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20140711/3f84809a/attachment.html>

More information about the Haskell-Cafe mailing list