[commit: ghc] master: Derive Generic instance for System.Exit.ExitCode (a5745d2)
git at git.haskell.org
git at git.haskell.org
Tue Apr 14 06:20:11 UTC 2015
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/a5745d2b3112312a9e8c486142fb99b9d02e9827/ghc
>---------------------------------------------------------------
commit a5745d2b3112312a9e8c486142fb99b9d02e9827
Author: Herbert Valerio Riedel <hvr at gnu.org>
Date: Tue Apr 14 01:12:22 2015 -0500
Derive Generic instance for System.Exit.ExitCode
Reviewed By: austin
Differential Revision: https://phabricator.haskell.org/D830
>---------------------------------------------------------------
a5745d2b3112312a9e8c486142fb99b9d02e9827
libraries/base/GHC/IO/Exception.hs | 5 +++--
libraries/base/changelog.md | 2 ++
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/libraries/base/GHC/IO/Exception.hs b/libraries/base/GHC/IO/Exception.hs
index b7e05b5..9cf78b3 100644
--- a/libraries/base/GHC/IO/Exception.hs
+++ b/libraries/base/GHC/IO/Exception.hs
@@ -1,5 +1,5 @@
{-# LANGUAGE Trustworthy #-}
-{-# LANGUAGE NoImplicitPrelude, MagicHash,
+{-# LANGUAGE DeriveGeneric, NoImplicitPrelude, MagicHash,
ExistentialQuantification #-}
{-# OPTIONS_GHC -funbox-strict-fields #-}
{-# OPTIONS_HADDOCK hide #-}
@@ -44,6 +44,7 @@ module GHC.IO.Exception (
) where
import GHC.Base
+import GHC.Generics
import GHC.List
import GHC.IO
import GHC.Show
@@ -225,7 +226,7 @@ data ExitCode
-- The exact interpretation of the code is
-- operating-system dependent. In particular, some values
-- may be prohibited (e.g. 0 on a POSIX-compliant system).
- deriving (Eq, Ord, Read, Show)
+ deriving (Eq, Ord, Read, Show, Generic)
instance Exception ExitCode
diff --git a/libraries/base/changelog.md b/libraries/base/changelog.md
index ea509af..56b9fae 100644
--- a/libraries/base/changelog.md
+++ b/libraries/base/changelog.md
@@ -31,6 +31,8 @@
* `Complex` now has a `Generic` instance
+ * `System.Exit.ExitCode` now has a `Generic` instance
+
## 4.8.0.0 *Mar 2015*
* Bundled with GHC 7.10.1
More information about the ghc-commits
mailing list