packages feed

bson-mapping 0.1.3.2 → 0.1.4

raw patch · 2 files changed

+10/−10 lines, 2 filesdep +compact-string-fixdep −textdep ~bson

Dependencies added: compact-string-fix

Dependencies removed: text

Dependency ranges changed: bson

Files

bson-mapping.cabal view
@@ -1,5 +1,5 @@ Name:               bson-mapping-Version:            0.1.3.2+Version:            0.1.4 License:            OtherLicense License-File:       LICENSE Author:             Francesco Mazzoli <f@mazzo.li>@@ -15,14 +15,14 @@  source-repository head     type:     git-    location: git://github.com/bitonic/bson-mapping.git+    location: git://github.com/rostayob/bson-mapping.git  Library   Build-Depends:      base >= 4 && < 5,                       template-haskell >= 2.5,                       th-lift >= 0.5.3,-                      bson >= 0.2,-                      text >= 1.1+                      bson >= 0.1.3,+                      compact-string-fix >= 0.3.1    hs-source-dirs:     src 
src/Data/Bson/Mapping.hs view
@@ -47,7 +47,7 @@  import Data.Bson import Data.Data               (Typeable)-import Data.Text (append, cons)+import Data.CompactString.UTF8 (append, cons)  import Language.Haskell.TH import Language.Haskell.TH.Lift ()@@ -194,14 +194,14 @@     genStmts [] _ = return ([], [])     genStmts (f : fs) doc = do       fvar <- newName "f"-      let stmt = bindS (varP fvar) $ [| lookup (nameBase f) $doc |]+      let stmt = bindS (varP fvar) $ [| lookup (u (nameBase f)) $doc |]       (fields, stmts) <- genStmts fs doc       return $ (return (f, VarE fvar) : fields, stmt : stmts)  -dataField, consField :: String-dataField = "_data"-consField = "_cons"+dataField, consField :: UString+dataField = u "_data"+consField = u "_cons"  {-| @@ -236,7 +236,7 @@ subDocument lab doc = [append lab (cons '.' l) := v | (l := v) <- doc]  getLabel :: Name -> Q Exp-getLabel n = [| (nameBase n) |]+getLabel n = [| u (nameBase n) |]  {-|