annotate tests/mr.ur @ 23:e1e451cf85bb

Simplify Reddit example more
author Adam Chlipala <adam@chlipala.net>
date Sat, 29 Sep 2012 10:34:11 -0400
parents 0140b1662994
children
rev   line source
adam@0 1 fun main () =
adam@15 2 doc <- Feed.fetch "http://feeds.feedburner.com/marginalrevolution/feed";
adam@8 3
adam@1 4 Feed.app (Feed.children
adam@8 5 (Feed.tagA "item" ())
adam@8 6 (Feed.tagC "link", Feed.tagC "title", Feed.tagC "content:encoded"))
adam@8 7 (fn ((), (link, title, content)) =>
adam@15 8 error <xml/>;
adam@8 9 debug ("URL: " ^ link);
adam@8 10 debug ("Title: " ^ title);
adam@8 11 debug ("Content: " ^ content))
adam@8 12 doc;
adam@0 13 return <xml>
adam@1 14 See stdout.
adam@0 15 </xml>