Hello community,

here is the log from the commit of package ghc-STMonadTrans for 
openSUSE:Factory checked in at 2016-12-06 14:24:03
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-STMonadTrans (Old)
 and      /work/SRC/openSUSE:Factory/.ghc-STMonadTrans.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "ghc-STMonadTrans"

Changes:
--------
--- /work/SRC/openSUSE:Factory/ghc-STMonadTrans/ghc-STMonadTrans.changes        
2016-09-24 15:22:50.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.ghc-STMonadTrans.new/ghc-STMonadTrans.changes   
2016-12-06 14:24:04.000000000 +0100
@@ -1,0 +2,5 @@
+Sun Nov  6 21:26:12 UTC 2016 - psim...@suse.com
+
+- Update to version 0.3.4 with cabal2obs.
+
+-------------------------------------------------------------------

Old:
----
  STMonadTrans-0.3.3.tar.gz

New:
----
  STMonadTrans-0.3.4.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ ghc-STMonadTrans.spec ++++++
--- /var/tmp/diff_new_pack.QEKJoU/_old  2016-12-06 14:24:05.000000000 +0100
+++ /var/tmp/diff_new_pack.QEKJoU/_new  2016-12-06 14:24:05.000000000 +0100
@@ -17,21 +17,20 @@
 
 
 %global pkg_name STMonadTrans
+%bcond_with tests
 Name:           ghc-%{pkg_name}
-Version:        0.3.3
+Version:        0.3.4
 Release:        0
 Summary:        A monad transformer version of the ST monad
 License:        BSD-3-Clause
-Group:          System/Libraries
+Group:          Development/Languages/Other
 Url:            https://hackage.haskell.org/package/%{pkg_name}
 Source0:        
https://hackage.haskell.org/package/%{pkg_name}-%{version}/%{pkg_name}-%{version}.tar.gz
 BuildRequires:  ghc-Cabal-devel
-# Begin cabal-rpm deps:
 BuildRequires:  ghc-array-devel
 BuildRequires:  ghc-mtl-devel
 BuildRequires:  ghc-rpm-macros
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
-# End cabal-rpm deps
 
 %description
 A monad transformer version of the ST monad Warning! This monad transformer
@@ -55,14 +54,14 @@
 %prep
 %setup -q -n %{pkg_name}-%{version}
 
-
 %build
 %ghc_lib_build
 
-
 %install
 %ghc_lib_install
 
+%check
+%cabal_test
 
 %post devel
 %ghc_pkg_recache

++++++ STMonadTrans-0.3.3.tar.gz -> STMonadTrans-0.3.4.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/STMonadTrans-0.3.3/Control/Monad/ST/Trans.hs 
new/STMonadTrans-0.3.4/Control/Monad/ST/Trans.hs
--- old/STMonadTrans-0.3.3/Control/Monad/ST/Trans.hs    2015-03-16 
09:18:25.000000000 +0100
+++ new/STMonadTrans-0.3.4/Control/Monad/ST/Trans.hs    2016-11-05 
11:53:40.000000000 +0100
@@ -130,6 +130,7 @@
 instance Eq (STRef s a) where
   STRef v1 == STRef v2 = isTrue# (sameMutVar# v1 v2)
 
+{-# NOINLINE runST #-}
 -- | Executes a computation in the 'STT' monad transformer
 runST :: Monad m => (forall s. STT s m a) -> m a
 runST m = let (STT f) = m
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/STMonadTrans-0.3.3/STMonadTrans.cabal 
new/STMonadTrans-0.3.4/STMonadTrans.cabal
--- old/STMonadTrans-0.3.3/STMonadTrans.cabal   2015-03-16 09:18:25.000000000 
+0100
+++ new/STMonadTrans-0.3.4/STMonadTrans.cabal   2016-11-05 11:53:40.000000000 
+0100
@@ -1,6 +1,6 @@
 name:          STMonadTrans
-version:       0.3.3
-cabal-version:  >= 1.6
+version:       0.3.4
+cabal-version:  >= 1.8
 license:       BSD3
 license-file:  LICENSE
 author:                Josef Svenningsson
@@ -37,3 +37,8 @@
   extensions:  CPP, MagicHash, UnboxedTuples, Rank2Types, FlexibleInstances,
         MultiParamTypeClasses, UndecidableInstances
 
+Test-Suite foo
+  type: detailed-0.9
+  hs-source-dirs: test
+  test-module: Test
+  build-depends: STMonadTrans, base, mtl, array, Cabal
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/STMonadTrans-0.3.3/dist/build/fooStub/fooStub-tmp/fooStub.hs 
new/STMonadTrans-0.3.4/dist/build/fooStub/fooStub-tmp/fooStub.hs
--- old/STMonadTrans-0.3.3/dist/build/fooStub/fooStub-tmp/fooStub.hs    
1970-01-01 01:00:00.000000000 +0100
+++ new/STMonadTrans-0.3.4/dist/build/fooStub/fooStub-tmp/fooStub.hs    
2016-11-05 11:53:40.000000000 +0100
@@ -0,0 +1,5 @@
+module Main ( main ) where
+import Distribution.Simple.Test.LibV09 ( stubMain )
+import Test ( tests )
+main :: IO ()
+main = stubMain tests
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/STMonadTrans-0.3.3/test/Test.hs 
new/STMonadTrans-0.3.4/test/Test.hs
--- old/STMonadTrans-0.3.3/test/Test.hs 1970-01-01 01:00:00.000000000 +0100
+++ new/STMonadTrans-0.3.4/test/Test.hs 2016-11-05 11:53:40.000000000 +0100
@@ -0,0 +1,37 @@
+module Test where
+
+import Control.Monad
+import Control.Monad.Trans
+import Control.Monad.ST.Trans
+
+import Data.Array
+
+import Distribution.TestSuite
+
+foo :: Int -> Maybe (Array Int Int)
+foo i = runSTArray $ do
+    arr <- newSTArray (1, 3) 0
+    lift $ guard $ i > 0
+    writeSTArray arr 2 i
+    return arr
+
+ups :: (Maybe (Array Int Int, Array Int Int))
+ups = (,) <$> foo 5 <*> foo 6
+
+main :: IO ()
+main = print ups
+
+tests :: IO [Test]
+tests = return [Test bar]
+  where
+    bar = TestInstance
+        { run = return $ Finished runUps
+        , name = "array creation"
+        , tags = []
+        , options = []
+        , setOption = \_ _ -> Right bar
+        }
+    runUps = case ups of
+      Just (a1,a2) | elems a1 /= elems a2 -> Pass
+                   | otherwise -> Fail "Only created one array."
+      _ -> Error "Got Nothing! Shouldn't happen."


Reply via email to