packages feed

array 0.5.3.0 → 0.5.4.0

raw patch · 5 files changed

+33/−8 lines, 5 filesdep ~basesetup-changedPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

Dependency ranges changed: base

API changes (from Hackage documentation)

- Data.Array: bounds :: () => Array i e -> (i, i)
+ Data.Array: bounds :: Array i e -> (i, i)
- Data.Array: elems :: () => Array i e -> [e]
+ Data.Array: elems :: Array i e -> [e]

Files

Data/Array/Base.hs view
@@ -43,12 +43,16 @@ import GHC.Base         ( IO(..), divInt# ) import GHC.Exts import GHC.Ptr          ( nullPtr, nullFunPtr )+import GHC.Show         ( appPrec ) import GHC.Stable       ( StablePtr(..) )+import GHC.Read         ( expectP, parens, Read(..) ) import GHC.Int          ( Int8(..),  Int16(..),  Int32(..),  Int64(..) ) import GHC.Word         ( Word8(..), Word16(..), Word32(..), Word64(..) ) import GHC.IO           ( stToIO ) import GHC.IOArray      ( IOArray(..),                           newIOArray, unsafeReadIOArray, unsafeWriteIOArray )+import Text.Read.Lex    ( Lexeme(Ident) )+import Text.ParserCombinators.ReadPrec ( prec, ReadPrec, step )  #include "MachDeps.h" @@ -479,7 +483,7 @@ {-# RULES "cmpUArray/Int" cmpUArray = cmpIntUArray #-}  -------------------------------------------------------------------------------- Showing IArrays+-- Showing and Reading IArrays  {-# SPECIALISE     showsIArray :: (IArray UArray e, Ix i, Show i, Show e) =>@@ -488,12 +492,24 @@  showsIArray :: (IArray a e, Ix i, Show i, Show e) => Int -> a i e -> ShowS showsIArray p a =-    showParen (p > 9) $+    showParen (p > appPrec) $     showString "array " .     shows (bounds a) .     showChar ' ' .     shows (assocs a) +{-# SPECIALISE+    readIArray :: (IArray UArray e, Ix i, Read i, Read e) =>+                   ReadPrec (UArray i e)+  #-}++readIArray :: (IArray a e, Ix i, Read i, Read e) => ReadPrec (a i e)+readIArray = parens $ prec appPrec $+               do expectP (Ident "array")+                  theBounds <- step readPrec+                  vals   <- step readPrec+                  return (array theBounds vals)+ ----------------------------------------------------------------------------- -- Flat unboxed arrays: instances @@ -784,6 +800,9 @@  instance (Ix ix, Show ix, Show e, IArray UArray e) => Show (UArray ix e) where     showsPrec = showsIArray++instance (Ix ix, Read ix, Read e, IArray UArray e) => Read (UArray ix e) where+    readPrec = readIArray  ----------------------------------------------------------------------------- -- Mutable arrays
LICENSE view
@@ -81,3 +81,4 @@   be a definition of the Haskell 98 Foreign Function Interface.  -----------------------------------------------------------------------------+
Setup.hs view
@@ -4,3 +4,4 @@  main :: IO () main = defaultMain+
array.cabal view
@@ -1,15 +1,15 @@+cabal-version: >= 1.10 name:          array-version:       0.5.3.0+version:       0.5.4.0+ -- NOTE: Don't forget to update ./changelog.md license:       BSD3 license-file:  LICENSE maintainer:    libraries@haskell.org-bug-reports:   http://ghc.haskell.org/trac/ghc/newticket?component=libraries%20%28other%29&keywords=array+bug-reports:   https://gitlab.haskell.org/ghc/packages/array/issues synopsis:      Mutable and immutable arrays category:      Data Structures build-type:    Simple-cabal-version: >=1.10-tested-with:   GHC==8.4.2, GHC==8.2.1, GHC==8.0.2 description:     In addition to providing the "Data.Array" module     <http://www.haskell.org/onlinereport/haskell2010/haskellch14.html as specified in the Haskell 2010 Language Report>,@@ -21,7 +21,7 @@  source-repository head   type:     git-  location: http://git.haskell.org/packages/array.git+  location: http://gitlab.haskell.org/ghc/packages/array.git  library   default-language: Haskell2010@@ -36,7 +36,7 @@       Trustworthy,       UnboxedTuples,       UnliftedFFITypes-  build-depends: base >= 4.9 && < 4.13+  build-depends: base >= 4.9 && < 4.14   ghc-options: -Wall   exposed-modules:       Data.Array
changelog.md view
@@ -1,5 +1,9 @@ # Changelog for [`array` package](http://hackage.haskell.org/package/array) +## 0.5.4.0  *July 2019*++* Add a `Read` instance for `UArray`+ ## 0.5.3.0  *Oct 2018*    * Bundled with GHC 8.6.2