File: Tests.hs

package info (click to toggle)
haskell-code-page 0.2.1-3
  • links: PTS
  • area: main
  • in suites: forky, sid, trixie
  • size: 88 kB
  • sloc: haskell: 221; ansic: 10; makefile: 7
file content (23 lines) | stat: -rw-r--r-- 544 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{-|
Module:      Tests
Copyright:   (C) 2016-2017 Ryan Scott
License:     BSD-style (see the file LICENSE)
Maintainer:  Ryan Scott
Stability:   Provisional
Portability: Portable

Ensures that functions from "System.IO.CodePage" work properly.
-}
module Main (main) where

import System.IO.CodePage

printUnicodeStrings :: IO ()
printUnicodeStrings = do
  putStrLn "κόσμε"
  putStrLn "→"
  putStrLn "☀☁☂☃☄"

main :: IO ()
main = withCP1252 $
       withCodePageOptions defaultOptions{chatty = True} cp65001 printUnicodeStrings