Skip to content

Commit 4260b7e

Browse files
committed
Bump package version and add since annotations.
1 parent 50a9ed5 commit 4260b7e

File tree

6 files changed

+36
-2
lines changed

6 files changed

+36
-2
lines changed

Changelog.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Changelog
22

3-
## Next
3+
## 0.3.0 (December 2021)
44

55
- Support for big-endian architectures.
66
- Added `GeneralCategory` data type and corresponding `generalCategoryAbbr`,

lib/Unicode/Char/General.hs

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,8 @@ part of the Unicode standard
109109
110110
__Note:__ the classes must be in the same order they are listed in the Unicode Standard,
111111
because some functions (e.g. 'generalCategory') rely on the 'Enum' instance.
112+
113+
@since 0.3.0
112114
-}
113115
data GeneralCategory
114116
-- L: Letter
@@ -163,6 +165,8 @@ data GeneralCategory
163165
)
164166

165167
-- | Abbreviation of 'GeneralCategory' used in the Unicode standard.
168+
--
169+
-- @since 0.3.0
166170
generalCategoryAbbr :: GeneralCategory -> String
167171
generalCategoryAbbr = \case
168172
UppercaseLetter -> "Lu"
@@ -204,6 +208,8 @@ This relies on the 'Enum' instance of 'GeneralCategory', which must remain in th
204208
same order as the categories are presented in the Unicode standard.
205209
206210
prop> show (generalCategory c) == show (Data.Char.generalCategory c)
211+
212+
@since 0.3.0
207213
-}
208214
{-# INLINE generalCategory #-}
209215
generalCategory :: Char -> GeneralCategory
@@ -233,6 +239,8 @@ __Note:__ this function is /not/ equivalent to 'Unicode.Char.General.Compat.isAl
233239
* 'OtherLetter' (@Lo@)
234240
* 'LetterNumber' (@Nl@)
235241
* @Other_Alphabetic@ [property](https://www.unicode.org/reports/tr44/#Other_Alphabetic)
242+
243+
@since 0.3.0
236244
-}
237245
{-# INLINE isAlphabetic #-}
238246
isAlphabetic :: Char -> Bool
@@ -253,6 +261,8 @@ following 'GeneralCategory's, or 'False' otherwise:
253261
* 'OtherNumber'
254262
255263
prop> isAlphaNum c == Data.Char.isAlphaNum c
264+
265+
@since 0.3.0
256266
-}
257267
isAlphaNum :: Char -> Bool
258268
isAlphaNum c = case generalCategory c of
@@ -272,6 +282,8 @@ of the Latin-1 subset of Unicode.
272282
This function returns 'True' if its argument has the 'GeneralCategory' 'Control'.
273283
274284
prop> isControl c == Data.Char.isControl c
285+
286+
@since 0.3.0
275287
-}
276288
isControl :: Char -> Bool
277289
isControl c = case generalCategory c of
@@ -289,6 +301,8 @@ following 'GeneralCategory's, or 'False' otherwise:
289301
* 'EnclosingMark'
290302
291303
prop> isMark c == Data.Char.isMark c
304+
305+
@since 0.3.0
292306
-}
293307
isMark :: Char -> Bool
294308
isMark c = case generalCategory c of
@@ -312,6 +326,8 @@ following 'GeneralCategory's, or 'True' otherwise:
312326
* 'NotAssigned'
313327
314328
prop> isPrint c == Data.Char.isPrint c
329+
330+
@since 0.3.0
315331
-}
316332
isPrint :: Char -> Bool
317333
isPrint c = case generalCategory c of
@@ -339,6 +355,8 @@ following 'GeneralCategory's, or 'False' otherwise:
339355
* 'OtherPunctuation'
340356
341357
prop> isPunctuation c == Data.Char.isPunctuation c
358+
359+
@since 0.3.0
342360
-}
343361
isPunctuation :: Char -> Bool
344362
isPunctuation c = case generalCategory c of
@@ -362,6 +380,8 @@ __Note:__ 'isWhiteSpace' is /not/ equivalent to 'Unicode.Char.General.Compat.isS
362380
* @U+0085@ NEXT LINE (NEL)
363381
* @U+2028@ LINE SEPARATOR
364382
* @U+2029@ PARAGRAPH SEPARATOR
383+
384+
@since 0.3.0
365385
-}
366386
{-# INLINE isWhiteSpace #-}
367387
isWhiteSpace :: Char -> Bool
@@ -377,6 +397,8 @@ following 'GeneralCategory's, or 'False' otherwise:
377397
* 'ParagraphSeparator'
378398
379399
prop> isSeparator c == Data.Char.isSeparator c
400+
401+
@since 0.3.0
380402
-}
381403
isSeparator :: Char -> Bool
382404
isSeparator c = case generalCategory c of
@@ -395,6 +417,8 @@ following 'GeneralCategory's, or 'False' otherwise:
395417
* 'OtherSymbol'
396418
397419
prop> isSymbol c == Data.Char.isSymbol c
420+
421+
@since 0.3.0
398422
-}
399423
isSymbol :: Char -> Bool
400424
isSymbol c = case generalCategory c of

lib/Unicode/Char/General/Compat.hs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ module Unicode.Char.General.Compat
2020
import Unicode.Char.General (GeneralCategory(..), generalCategory)
2121

2222
-- | Same as 'isLetter'.
23+
--
24+
-- @since 0.3.0
2325
{-# INLINE isAlpha #-}
2426
isAlpha :: Char -> Bool
2527
isAlpha = isLetter
@@ -40,6 +42,8 @@ __Note:__ this function is /not/ equivalent to 'Unicode.Char.General.isAlphabeti
4042
See the description of 'Unicode.Char.General.isAlphabetic' for further details.
4143
4244
prop> isLetter c == Data.Char.isLetter c
45+
46+
@since 0.3.0
4347
-}
4448
{-# INLINE isLetter #-}
4549
isLetter :: Char -> Bool
@@ -63,6 +67,8 @@ plus the following:
6367
* @U+2029@ PARAGRAPH SEPARATOR
6468
6569
prop> isSpace c == Data.Char.isSpace c
70+
71+
@since 0.3.0
6672
-}
6773
isSpace :: Char -> Bool
6874
isSpace '\t' = True

lib/Unicode/Char/Numeric.hs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ following 'GeneralCategory's, or 'False' otherwise:
3030
* 'OtherNumber'
3131
3232
prop> isNumber c == Data.Char.isNumber c
33+
34+
@since 0.3.0
3335
-}
3436
isNumber :: Char -> Bool
3537
isNumber c = case generalCategory c of

lib/Unicode/Internal/Bits.hs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ the bitmap starting at @addr@, then convert it to an Int.
6161
The caller must make sure that:
6262
6363
* @ceiling (addr + (n * 8))@ is legally accessible @Word8@.
64+
65+
@since 0.3.0
6466
-}
6567
lookupIntN
6668
:: Addr# -- ^ Bitmap address

unicode-data.cabal

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cabal-version: 2.2
22
name: unicode-data
3-
version: 0.2.0
3+
version: 0.3.0
44
synopsis: Access Unicode character database
55
description:
66
@unicode-data@ provides Haskell APIs to efficiently access the Unicode

0 commit comments

Comments
 (0)