Hets - the Heterogeneous Tool Set
Copyright(c) Christian Maeder DFKI GmbH 2010
LicenseGPLv2 or higher, see LICENSE.txt
MaintainerChristian.Maeder@dfki.de
Stabilityprovisional
Portabilityportable
Safe HaskellSafe

Common.IO

Description

reading and writing files changed between ghc-6.10.4 and ghc-6.12.1 from latin1 to utf8.

This module allows to continue reading and writing latin1 (DOL) files. However, this module does not support to write utf8 files with ghc-6.10.4 or earlier versions.

The encoding only effects the contents. The encoding of file names is always utf8.

Synopsis

Documentation

data Enc Source #

Constructors

Latin1 
Utf8 

Instances

Instances details
Show Enc Source # 
Instance details

Defined in Common.IO

Methods

showsPrec :: Int -> Enc -> ShowS

show :: Enc -> String

showList :: [Enc] -> ShowS

readEncFile :: Enc -> String -> IO String Source #

writeEncFile :: Enc -> String -> String -> IO () Source #

setStdEnc :: Enc -> IO () Source #

set encoding of stdin and stdout

catchIOException :: a -> IO a -> IO a Source #