packages feed

void 0.5.1 → 0.5.2

raw patch · 2 files changed

+24/−2 lines, 2 files

Files

Data/Void.hs view
@@ -1,3 +1,4 @@+{-# LANGUAGE CPP #-} ----------------------------------------------------------------------------- -- | -- Module      :  Data.Void@@ -12,8 +13,23 @@ module Data.Void (Void, absurd) where  import Data.Semigroup (Semigroup(..))+import Data.Ix+#ifdef GLASGOW_HASKELL > 610+import Data.Data+import Data.Typeable+#endif -newtype Void = Void Void deriving (Eq,Ord,Show,Read)+#ifdef GLASGOW_HASKELL < 700+data Void = Void !Void +#else+newtype Void = Void Void+#endif+  deriving +  ( Eq, Ord, Show, Read+#ifdef GLASGOW_HASKELL > 610+  , Data, Typeable+#endif+  )  -- | Since Void values are logically uninhabited, this witnesses the logical -- reasoning tool of 'ex falso quodlibet'.@@ -22,3 +38,9 @@  instance Semigroup Void where   a <> _ = a++instance Ix Void where+  range _ = []+  index _ = absurd+  inRange _ = absurd+  rangeSize _ = 0 
void.cabal view
@@ -1,6 +1,6 @@ name:          void category:      Data Structures-version:       0.5.1+version:       0.5.2 license:       BSD3 cabal-version: >= 1.6 license-file:  LICENSE