packages feed

ascii 1.2.4.0 → 1.2.5.0

raw patch · 4 files changed

+267/−7 lines, 4 filesdep +ascii-caselessdep ~basePVP ok

version bump matches the API change (PVP)

Dependencies added: ascii-caseless

Dependency ranges changed: base

API changes (from Hackage documentation)

+ ASCII: data CaselessChar

Files

ascii.cabal view
@@ -1,7 +1,7 @@ cabal-version: 3.0  name: ascii-version: 1.2.4.0+version: 1.2.5.0 synopsis: The ASCII character set and encoding category: Data, Text @@ -15,9 +15,9 @@ maintainer: Chris Martin, Julie Moronuki  homepage: https://github.com/typeclasses/ascii-bug-Reports: https://github.com/typeclasses/ascii/issues+bug-reports: https://github.com/typeclasses/ascii/issues -build-type: Simple+extra-source-files: *.md  source-repository head     type: git@@ -31,17 +31,21 @@         NoImplicitPrelude      build-depends:-        base >= 4.14 && < 4.18-      , text ^>= 1.2.4.1 || ^>= 2.0+        base ^>= 4.14 || ^>= 4.15 || ^>= 4.16 || ^>= 4.17+      , text ^>= 1.2.4 || ^>= 2.0  library     import: base     hs-source-dirs: library      build-depends:-        bytestring ^>= 0.10 || ^>= 0.11+        bytestring ^>= 0.10.12 || ^>= 0.11      exposed-modules: ASCII++    build-depends: ascii-caseless == 0.0.0.*+    reexported-modules:+        ASCII.Caseless      build-depends: ascii-char == 1.0.0.*     reexported-modules:
+ changelog.md view
@@ -0,0 +1,176 @@+### 1.2.5.0 (2022-01-02)++Add the `ASCII.Caseless` module (re-exported from the `ascii-caseless` package)++Additions to the `ASCII` module:++* `CaselessChar`++### 1.2.4.1 (2022-12-30)++Metadata changes only++### 1.2.4.0 (2022-12-23)++Bump version of `ascii-case` to `1.0.1`. This adds the following function to the+`ASCII.Case` module:++```haskell+opposite :: Case -> Case+```++### 1.2.3.0 (2022-05-04)++Add `isVisible :: Char -> Bool`. Visible characters include all print characters+other than `Space`.++### 1.2.2.0 (2022-04-29)++Add `type UnicodeChar = Data.Char.Char` type alias to `ASCII` module++### 1.2.1.0 (2022-04-29)++New polymorphic narrowing functions:++* `toAsciiCharMaybe :: CharSuperset char => char -> Maybe Char`+* `toDigitMaybe :: DigitSuperset char => char -> Maybe Digit`+* `toHexCharMaybe :: HexCharSuperset char => char -> Maybe HexChar`++New monomorphic character conversion functions:++* `digitToWord8 :: Digit -> Word8`+* `word8ToDigitMaybe :: Word8 -> Maybe Digit`+* `word8ToDigitUnsafe :: Word8 -> Digit`+* `digitToChar :: Digit -> Char`+* `charToDigitMaybe :: Char -> Maybe Digit`+* `charToDigitUnsafe :: Char -> Digit`+* `digitToUnicode :: Digit -> Unicode.Char`+* `unicodeToDigitMaybe :: Unicode.Char -> Maybe Digit`+* `unicodeToDigitUnsafe :: Unicode.Char -> Digit`+* `hexCharToWord8 :: HexChar -> Word8`+* `word8ToHexCharMaybe :: Word8 -> Maybe HexChar`+* `word8ToHexCharUnsafe :: Word8 -> HexChar`+* `hexCharToChar :: HexChar -> Char`+* `charToHexCharMaybe :: Char -> Maybe HexChar`+* `charToHexCharUnsafe :: Char -> HexChar`+* `hexCharToUnicode :: HexChar -> Unicode.Char`+* `unicodeToHexCharMaybe :: Unicode.Char -> Maybe HexChar`+* `unicodeToHexCharUnsafe :: Unicode.Char -> HexChar`++### 1.2.0.0 (2022-04-20)++Update to `ascii-numbers` version `1.1.0`. The major change is that there are+now `Lift` instances for `Digit` and `HexChar`.++### 1.1.3.0++Added functions `digitString` and `hexCharString`++### 1.1.2.0++Add dependency on `ascii-numbers`++New modules:++* `ASCII.Decimal`+* `ASCII.Hexadecimal`++New types:++* `Digit`+* `HexChar`++New classes:++* `DigitSuperset`+* `DigitStringSuperset`+* `HexCharSuperset`+* `HexStringSuperset`++New functions:++* `showIntegralDecimal`+* `showIntegralHexadecimal`+* `readIntegralDecimal`+* `readIntegralHexadecimal`++* `showNaturalDigits`+* `readNaturalDigits`+* `showNaturalHexChars`+* `readNaturalHexChars`++* `showNaturalDecimal`+* `showNaturalHexadecimal`+* `readNaturalDecimal`+* `readNaturalHexadecimal`++Dropped support for old versions:++* Drop support for `base` 4.11 (GHC 8.4)+* Drop support for `base` 4.12 (GHC 8.6)++### 1.1.1.4++Switch test-suite over to `hedgehog`++### 1.1.1.2++Support GHC 9.2++### 1.1.1.0++New functions:++  - `isAlphaNum`+  - `isLetter`+  - `isDigit`+  - `isOctDigit`+  - `isHexDigit`+  - `isSpace`+  - `isPunctuation`+  - `isSymbol`++### 1.1.0.0++The dependency on the 'data-ascii' package is removed, and the following modules+are no longer re-exported:++  - `Data.Ascii`+  - `Data.Ascii.Blaze`+  - `Data.Ascii.ByteString`+  - `Data.Ascii.Word8`++### 1.0.1.6++Add a test suite++Raise `text` lower bound to 1.2.3++### 1.0.1.4++Support GHC 9.0++### 1.0.1.2++Support `bytestring-0.11`++### 1.0.1.0++New functions:++  - `byteStringToUnicodeStringMaybe`+  - `unicodeStringToByteStringMaybe`+  - `byteListToUnicodeStringMaybe`+  - `unicodeStringToByteListMaybe`+  - `convertCharMaybe`+  - `convertCharOrFail`+  - `convertStringMaybe`+  - `convertStringOrFail`++### 1.0.0.2++Support GHC 8.10++### 1.0.0.0++Completely redesigned the library
library/ASCII.hs view
@@ -12,7 +12,10 @@  module ASCII   (-    {- * @Char@ -} {- $char -} Char, UnicodeChar,+    {- * @Char@ -}+    {- ** ASCII -} {- $char -} Char,+    {- ** Unicode -} UnicodeChar,+    {- ** Case-insensitive -} {- $caselessChar -} CaselessChar,      {- * Character classifications -}     {- ** Print/control groups -} {- $groups -}@@ -96,6 +99,7 @@   where  import ASCII.Case (Case (..))+import ASCII.Caseless (CaselessChar) import ASCII.Char (Char) import ASCII.Decimal (Digit, DigitStringSuperset, DigitSuperset) import ASCII.Group (Group (..))@@ -135,6 +139,12 @@ {- $char  See also: "ASCII.Char"++-}++{- $caselessChar++See also: "ASCII.Caseless"  -} 
+ readme.md view
@@ -0,0 +1,70 @@+## What is ASCII?++The *American Standard Code for Information Interchange* (ASCII) comprises a set+of 128 characters, each represented by 7 bits. 33 of these characters are+"control codes"; a few of these are still in use, but most are obsolete relics+of the early days of computing. The other 95 are "printable characters" such as+letters and numbers, mostly corresponding to the keys on an American English+keyboard.++Nowadays instead of ASCII we typically work with text using an encoding such as+UTF-8 that can represent the entire Unicode character set, which includes over a+hundred thousand characters and is not limited to the symbols of any particular+writing system or culture. However, ASCII is still relevant to network+protocols; for example, we can see it in the specification of [HTTP message+headers][ietf].++There is a convenient relationship between ASCII and Unicode: the ASCII+characters are the first 128 characters of the much larger Unicode character+set. The [C0 Controls and Basic Latin][unicode] section of the Unicode standard+contains a list of all the ASCII characters.++## Haskell packages++This repository contains the main API, the [`ASCII`][ascii] module in the+`ascii` package, which is an amalgamation of smaller packages in other+repositories.++  * If you only need the ASCII [`Char`][char] type, you can use the+    `ascii-char` package, which is minimal so that it can be kept stable.++  * The `ascii-group` package defines the [`Group`][group] type (`Control` and+    `Printable`), and the `ascii-case` package defines the [`Case`][case] type+    (`UpperCase` and `LowerCase`). These package are also small and stable.++  * The `ascii-predicates` package provides [additional ways of categorizing+    characters][predicates] similar to what you can find in [the `base`+    package][base].++  * For case-insensitivity, use the `ascii-caseless` package.++  * The `ascii-superset` package defines [`CharSuperset` and+    `StringSuperset`][superset] classes to generalize types that represent+    characters and strings, respectively, in character sets larger than ASCII.+    It also defines the [`ASCII`][refinement] type constructor, which is used+    to indicate that a value from some ASCII superset is confined to ASCII.++  * The `ascii-numbers` package provides utilities for working with numbers+    represented using ASCII digits 0-9, ASCII letters A-F to represent+    hexadecimal digits 10-15, and the `HypenMinus` character for negation.++  * The `ascii-th` package provides a [quasi-quoter][qq] that allows one to+    safely and conveniently express ASCII string literals. The generated+    expressions are polymorphic and can take the form of any type belonging to+    the `StringSuperset` class, including `[ASCII.Char]`, [`String`][string],+    [`ByteString`][bytestring], and [`Text`][text].++  [ietf]: https://tools.ietf.org/html/rfc7230#section-1.2+  [unicode]: https://www.unicode.org/charts/PDF/U0000.pdf+  [ascii]: https://hackage.haskell.org/package/ascii/docs/ASCII.html+  [char]: https://hackage.haskell.org/package/ascii-char/docs/ASCII-Char.html+  [group]: https://hackage.haskell.org/package/ascii-group/docs/ASCII-Group.html+  [case]: https://hackage.haskell.org/package/ascii-case/docs/ASCII-Case.html+  [predicates]: https://hackage.haskell.org/package/ascii-predicates/docs/ASCII-ListsAndPredicates.html+  [base]: https://hackage.haskell.org/package/base/docs/Data-Char.html+  [superset]: https://hackage.haskell.org/package/ascii-superset/docs/ASCII-Superset.html+  [refinement]: https://hackage.haskell.org/package/ascii-superset/docs/ASCII-Refinement.html+  [qq]: https://hackage.haskell.org/package/ascii-th/docs/ASCII-QuasiQuoters.html+  [string]: https://hackage.haskell.org/package/base/docs/Data-String.html+  [bytestring]: https://hackage.haskell.org/package/bytestring+  [text]: https://hackage.haskell.org/package/text