packages feed

word8 0.0.1 → 0.0.2

raw patch · 3 files changed

+17/−4 lines, 3 filesdep ~base

Dependency ranges changed: base

Files

Data/Char8.hs view
@@ -1,6 +1,11 @@ {-# LANGUAGE MagicHash #-} --- | Char8 library to be used with Data.ByteString.Char8+-- | Char8 library to be used with Data.ByteString.Char8.+-- All function assumes that only 8bit part of 'Char' is used+-- and it is encoded in Latin-1 (ISO-8859-1).+-- All utility functions are supposed to work as if+-- those of 'Data.Char'. Exceptions are described in+-- the function documentations.  module Data.Char8 (   -- * Character classification@@ -99,7 +104,7 @@ isAscii c = _nul <= c && c <= _del  isLatin1 :: Char -> Bool-isLatin1 _ = True+isLatin1 (C# c#) = ord# c# <# 0xff#  isAsciiUpper :: Char -> Bool isAsciiUpper c = 'A' <= c && c <= 'Z'@@ -109,6 +114,7 @@  ---------------------------------------------------------------- +-- | Micro sign/mu (0xb5) and small letter Y with diaeresis (0xff) remain the same. toUpper :: Char -> Char toUpper c@(C# c#)   | c == _germandbls = c@@ -120,6 +126,7 @@   | isUpper c = C# (chr# (ord# c# +# 32#))   | otherwise = c +-- | Micro sign/mu (0xb5) and small letter Y with diaeresis (0xff) remain the same. toTitle :: Char -> Char toTitle = toUpper 
Data/Word8.hs view
@@ -1,4 +1,8 @@--- | Word8 library to be used with Data.ByteString+-- | Word8 library to be used with Data.ByteString.+-- All function assumes that 'Word8' is encoded in Latin-1 (ISO-8859-1).+-- All utility functions are supposed to work as if+-- those of 'Data.Char'. Exceptions are described in+-- the function documentations.  module Data.Word8 (   -- * Re-exporting@@ -125,6 +129,7 @@  ---------------------------------------------------------------- +-- | Micro sign/mu (0xb5) and small letter Y with diaeresis (0xff) remain the same. toUpper :: Word8 -> Word8 toUpper w   | w == _germandbls = w@@ -136,6 +141,7 @@   | isUpper w = w + _space   | otherwise = w +-- | Micro sign/mu (0xb5) and small letter Y with diaeresis (0xff) remain the same. toTitle :: Word8 -> Word8 toTitle = toUpper 
word8.cabal view
@@ -1,5 +1,5 @@ Name:                   word8-Version:                0.0.1+Version:                0.0.2 Author:                 Kazu Yamamoto <kazu@iij.ad.jp> Maintainer:             Kazu Yamamoto <kazu@iij.ad.jp> License:                BSD3