Skip to content

@beastaugh /HDBC-mysql_GHC7.diff
Created

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Patch to get HDBC-mysql running on GHC 7.0
diff -rN old-HDBC-mysql/Database/HDBC/MySQL/Connection.hsc new-HDBC-mysql/Database/HDBC/MySQL/Connection.hsc
2c2
< {-# OPTIONS -fglasgow-exts #-}
---
> {-# LANGUAGE ForeignFunctionInterface, ScopedTypeVariables, EmptyDataDecls #-}
125c125
< mysql_autocommit mysql_ 0
---
> _ <- mysql_autocommit mysql_ 0
674c674
< Types.execute stmt []
---
> _ <- Types.execute stmt []
689c689
< Types.execute stmt []
---
> _ <- Types.execute stmt []
834d833
<
diff -rN old-HDBC-mysql/HDBC-mysql.cabal new-HDBC-mysql/HDBC-mysql.cabal
13c13
< Build-Depends: base >= 2 && < 4, bytestring, time, utf8-string, HDBC >= 2.1.0
---
> Build-Depends: base >= 2 && < 5, bytestring, time, utf8-string, HDBC >= 2.1.0
diff -rN old-HDBC-mysql/Setup.lhs new-HDBC-mysql/Setup.lhs
31,32c31,32
< mysql_config <- findProgramOnPath "mysql_config" verbosity
< mysql_config5 <- findProgramOnPath "mysql_config5" verbosity
---
> mysql_config <- findProgramLocation verbosity "mysql_config"
> mysql_config5 <- findProgramLocation verbosity "mysql_config5"
diff -rN old-HDBC-mysql/testsrc/TestSbasics.hs new-HDBC-mysql/testsrc/TestSbasics.hs
124,125c124
< try $ withTransaction dbh (\_ -> do sExecuteMany sth rows
< fail "Foo")
---
> try $ withTransaction dbh (const $ sExecuteMany sth rows >> fail "Foo") :: IO (Either SomeException a)
diff -rN old-HDBC-mysql/testsrc/Testbasics.hs new-HDBC-mysql/testsrc/Testbasics.hs
141,142c141
< try $ withTransaction dbh (\_ -> do executeMany sth rows
< fail "Foo")
---
> try $ withTransaction dbh (const $ executeMany sth rows >> fail "Foo") :: IO (Either SomeException a)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.