3rd option for file handling

This commit is contained in:
Armin Friedl 2016-08-07 12:18:01 +02:00
parent 419cad6cab
commit 8228e3cdaf

View file

@ -60,6 +60,9 @@ runEditor f = do
-> ByteString.Lazy for lazy, fast
- Text.IO.hGetContents: strict, needs 2x file size while reading in
-> filesize == 2xRAM = bad
- Pass the handler around instead of filename, close at exit
-> works with all above options (incl. the lazy variants, i think)
-> locks the file MultiReader/SingleWriter for free (i think)
-}
content `seq` hClose handle
BrickMain.defaultMain theApp (initialState f content)