diff options
| author | fiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2009-12-31 16:48:21 +0000 |
|---|---|---|
| committer | fiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2009-12-31 16:48:21 +0000 |
| commit | aab574f9ef78792e53bfc55aa58635ecaf8b2a90 (patch) | |
| tree | 28ec7452cf972478380b25f0da2487f55354e1b4 /src/hsmarkdown.hs | |
| parent | 1b3d5896c7ffe976daac0fb3057526e52c0cfb44 (diff) | |
Use System.IO.UTF8 only if ghc < 6.12.
GHC >= 6.12 (base >= 4.2) uses iconv to convert to unicode
Strings.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@1748 788f1e2b-df1e-0410-8736-df70ead52e1b
Diffstat (limited to 'src/hsmarkdown.hs')
| -rw-r--r-- | src/hsmarkdown.hs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/hsmarkdown.hs b/src/hsmarkdown.hs index ed4695193..3f689d4ec 100644 --- a/src/hsmarkdown.hs +++ b/src/hsmarkdown.hs @@ -29,8 +29,13 @@ Wrapper around pandoc that emulates Markdown.pl as closely as possible. module Main where import System.Process import System.Environment ( getArgs ) +-- Note: ghc >= 6.12 (base >=4.2) supports unicode through iconv +-- So we use System.IO.UTF8 only if we have an earlier version +#if MIN_VERSION_base(4,2,0) +#else import Prelude hiding ( putStr, putStrLn, writeFile, readFile, getContents ) import System.IO.UTF8 +#endif import Control.Monad (forM_) main :: IO () |
