packages feed

xcb-types 0.10.0 → 0.11.0

raw patch · 4 files changed

+11/−4 lines, 4 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

+ Data.XCB.Types: Length :: typ -> Expression typ -> GenStructElem typ

Files

Data/XCB/FromXML.hs view
@@ -28,9 +28,7 @@ import qualified Data.Map as Map import Data.Maybe -import Control.Applicative ((<$>)) import Control.Monad-import Control.Monad.Fail (MonadFail) import Control.Monad.Reader  import System.IO (openFile, IOMode (ReadMode), hSetEncoding, utf8, hGetContents)@@ -397,6 +395,11 @@     | el `named` "fd" = do         name <- el `attr` "name"         return $ Fd name++    | el `named` "length" = do+        expr <- firstChild el >>= expression+        let typ = mkType "CARD32"+        return $ Length typ expr      | otherwise = let name = elName el                   in error $ "I don't know what to do with structelem "
Data/XCB/Pretty.hs view
@@ -149,6 +149,8 @@                       ,text mname                       ,text lname                       ]+    toDoc (Length _ expr)+        = text "length" <+> parens (toDoc expr)   instance Pretty a => Pretty (GenBitCase a) where
Data/XCB/Types.hs view
@@ -102,6 +102,7 @@     | Switch Name (Expression typ) (Maybe Alignment) [GenBitCase typ]     | Doc (Maybe String) (Map Name String) [(String, String)]     | Fd String+    | Length typ (Expression typ)  deriving (Show, Functor)  data GenBitCase typ
xcb-types.cabal view
@@ -1,6 +1,6 @@ Name:         xcb-types-Version:      0.10.0-Cabal-Version:  >= 1.6+Version:      0.11.0+Cabal-Version:  >= 1.10 Synopsis:     Parses XML files used by the XCB project Description:   This package provides types which mirror the structures   used in the XCB code generation XML files.@@ -41,5 +41,6 @@                   Data.XCB.FromXML   Other-modules:   Data.XCB.Utils+ Default-Language: Haskell2010   Ghc-Options:     -Wall