Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into feature/general_cat…
Browse files Browse the repository at this point in the history
…egory

# Conflicts:
#	appveyor.yml
#	lib/Unicode/Internal/Bits.hs
  • Loading branch information
wismill committed Nov 22, 2021
2 parents eb03cfa + e3208a4 commit 2ace84e
Show file tree
Hide file tree
Showing 7 changed files with 62 additions and 30 deletions.
66 changes: 44 additions & 22 deletions .github/workflows/haskell.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ jobs:
# Location of packcheck.sh
# ------------------------------------------------------------------------
PACKCHECK_LOCAL_PATH: "./packcheck.sh"
PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/harendra-kumar/packcheck"
PACKCHECK_GITHUB_COMMIT: "37bbe8a79ad5136e654e48e03ec519060a5b11e6"
PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/composewell/packcheck"
PACKCHECK_GITHUB_COMMIT: "v0.6.0"

# ------------------------------------------------------------------------
# Build options
Expand All @@ -42,55 +42,77 @@ jobs:
fail-fast: false
matrix:
name:
[ Ubuntu+GHC822, Ubuntu+GHC865, Ubuntu+GHC844
, Ubuntu+GHC884, Ubuntu+GHC8102+exe
, MacOS+GHC884+exe
, Hlint ]
cabal_version: [3.2]
- 7.10.3
- 8.0.2
- 8.2.2
- 8.4.4
- 8.8.4+macOS+exe
- 8.6.5
- 8.8.4
- 8.10.7+exe
- 9.0.1+exe
- 9.2.1
- hlint

include:

- name: Ubuntu+GHC7103
- name: 7.10.3
ghc_version: 7.10.3
runner: ubuntu-latest
cabal_version: 3.2

- name: Ubuntu+GHC802
- name: 8.0.2
ghc_version: 8.0.2
runner: ubuntu-latest
cabal_version: 3.2

- name: Ubuntu+GHC822
- name: 8.2.2
ghc_version: 8.2.2
runner: ubuntu-latest
cabal_version: 3.2

- name: Ubuntu+GHC844
- name: 8.4.4
ghc_version: 8.4.4
runner: ubuntu-latest
cabal_version: 3.2

- name: Ubuntu+GHC865
- name: 8.6.5
ghc_version: 8.6.5
runner: ubuntu-latest
cabal_version: 3.2

- name: Ubuntu+GHC884
- name: 8.8.4
ghc_version: 8.8.4
runner: ubuntu-latest
cabal_version: 3.2

- name: 8.8.4+macOS+exe
ghc_version: 8.8.4
pack_options: CABAL_BUILD_OPTIONS="-f ucd2haskell"
runner: macos-latest
cabal_version: 3.2

- name: Ubuntu+GHC8102+exe
ghc_version: 8.10.2
- name: 8.10.7+exe
ghc_version: 8.10.7
pack_options: CABAL_BUILD_OPTIONS="-f ucd2haskell"
runner: ubuntu-latest
cabal_version: 3.2

- name: Ubuntu+GHC901+exe
- name: 9.0.1+exe
ghc_version: 9.0.1
pack_options: CABAL_BUILD_OPTIONS="-f ucd2haskell"
runner: ubuntu-latest
cabal_version: 3.2

- name: Hlint
pack_options: HLINT_OPTIONS="lint" HLINT_TARGETS="lib exe"
- name: 9.2.1
ghc_version: 9.2.1
runner: ubuntu-latest
cabal_version: 3.6

- name: MacOS+GHC884+exe
ghc_version: 8.8.4
pack_options: CABAL_BUILD_OPTIONS="-f ucd2haskell"
runner: macos-latest
- name: hlint
pack_options: HLINT_OPTIONS="lint" HLINT_TARGETS="lib exe"
runner: ubuntu-latest
cabal_version: 3.2

steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 2 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
## 0.2.0 (November 2021)

* Update to [Unicode 14.0.0](https://www.unicode.org/versions/Unicode14.0.0/).
* Add `Unicode.Char.Identifiers` supporting Unicode Identifier and Pattern
Syntax.

## 0.1.0.1 (Jul 2021)

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,6 @@ $ cabal-docspec --check-properties --property-variables c
`unicode-data` is an [open source](https://github.com/composewell/unicode-data)
project available under a liberal [Apache-2.0 license](LICENSE).

## Contributing to Streamly
## Contributing

As an open project we welcome contributions.
4 changes: 2 additions & 2 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ environment:
# version.
#STACKVER: "1.6.5"
STACK_UPGRADE: "y"
RESOLVER: "lts-18.16"
RESOLVER: "lts-18.17"
STACK_ROOT: "c:\\sr"

# ------------------------------------------------------------------------
Expand All @@ -60,7 +60,7 @@ environment:
# If you have not committed packcheck.sh in your repo at PACKCHECK_LOCAL_PATH
# then it is automatically pulled from this URL.
PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/composewell/packcheck"
PACKCHECK_GITHUB_COMMIT: "37bbe8a79ad5136e654e48e03ec519060a5b11e6"
PACKCHECK_GITHUB_COMMIT: "v0.6.0"

# Override the temp directory to avoid sed escaping issues
# See https://github.com/haskell/cabal/issues/5386
Expand Down
5 changes: 2 additions & 3 deletions lib/Unicode/Char/Identifiers.hs
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,12 @@ isXIDContinue = P.isXID_Continue
isXIDStart :: Char -> Bool
isXIDStart = P.isXID_Start

-- | Returns 'True' is a pattern syntax character.
-- | Returns 'True' if a character is a pattern syntax character.
{-# INLINE isPatternSyntax #-}
isPatternSyntax :: Char -> Bool
isPatternSyntax = P.isPattern_Syntax

-- | Returns 'True' is a pattern whitespace character.
-- | Returns 'True' if a character is a pattern whitespace character.
{-# INLINE isPatternWhitespace #-}
isPatternWhitespace :: Char -> Bool
isPatternWhitespace = P.isPattern_White_Space

9 changes: 9 additions & 0 deletions lib/Unicode/Internal/Bits.hs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ module Unicode.Internal.Bits
lookupIntN
) where

#include "MachDeps.h"

import Data.Bits (finiteBitSize, popCount)
import GHC.Exts
(Addr#, Int(..), Word(..),
Expand All @@ -26,6 +28,9 @@ import GHC.Exts
#if MIN_VERSION_base(4,16,0)
import GHC.Exts (word8ToWord#)
#endif
#ifdef WORDS_BIGENDIAN
import GHC.Exts (byteSwap#)
#endif

-- | @lookup64 addr index@ looks up the bit stored at bit index @index@ using a
-- bitmap starting at the address @addr@. Looks up the 64-bit word containing
Expand All @@ -43,7 +48,11 @@ lookupBit64 addr# (I# index#) = W# (word## `and#` bitMask##) /= 0
_ -> popCount fbs -- this is a really weird architecture

wordIndex# = index# `uncheckedIShiftRL#` logFbs#
#ifdef WORDS_BIGENDIAN
word## = byteSwap# (indexWordOffAddr# addr# wordIndex#)
#else
word## = indexWordOffAddr# addr# wordIndex#
#endif
bitIndex# = index# `andI#` fbs#
bitMask## = 1## `uncheckedShiftL#` bitIndex#

Expand Down
4 changes: 2 additions & 2 deletions unicode-data.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ tested-with: GHC==7.10.3
, GHC==8.2.2
, GHC==8.4.4
, GHC==8.6.5
, GHC==8.8.3
, GHC==8.8.4
, GHC==8.10.2
, GHC==8.10.7
, GHC==9.0.1
, GHC==9.2.1

extra-source-files:
Changelog.md
Expand Down

0 comments on commit 2ace84e

Please sign in to comment.