From c8a64b581e4d4cac5a82e4ea3784d007affb83b6 Mon Sep 17 00:00:00 2001 From: Kevin Brubeck Unhammer Date: Thu, 16 May 2019 15:37:04 +0200 Subject: [PATCH] Note that -fno-full-laziness may be needed --- xml-conduit/README.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/xml-conduit/README.md b/xml-conduit/README.md index 8f43e206..27719806 100644 --- a/xml-conduit/README.md +++ b/xml-conduit/README.md @@ -17,3 +17,12 @@ package](http://www.stackage.org/package/xml-hamlet) provides a more convenient syntax for creating XML documents. For a more thorough tutorial on this library, please see [http://www.yesodweb.com/book/xml](http://www.yesodweb.com/book/xml). + +### Ensuring constant memory usage + +If you experience unnecessarily high/increasing memory usage with `Text.XML.Stream.Parse`, you may want to compile `xml-conduit` with `-fno-full-laziness`. You can tell `stack` to use the flag only for this package by putting the following lines into `stack.yaml`: + +``` +ghc-options: + xml-conduit: -fno-full-laziness +```