From 8147fa3278d4a51d82d794d23c039289f6dd9446 Mon Sep 17 00:00:00 2001
From: Ryan Scott <ryan.gl.scott@gmail.com>
Date: Fri, 13 Apr 2018 12:54:31 -0400
Subject: [PATCH] Correct FixIOException's @since annotation retroactively

Summary:
In D4113, a `FixIOException` data type was added with a
`@since TODO` annotation, but it seems that `TODO` made it out into
`base-4.11` itself. I've (retroactively) fixed this and added an
entry to the `base-4.11` entry in the `changelog`.

Test Plan: Read it

Reviewers: dfeuer, hvr, bgamari

Reviewed By: dfeuer

Subscribers: thomie, carter

GHC Trac Issues: #14356, #15025

Differential Revision: https://phabricator.haskell.org/D4578

(cherry picked from commit ce27c7d5fe3c335dcc354b70fdfc17831a6848f6)
---
 libraries/base/GHC/IO/Exception.hs | 7 +++++--
 libraries/base/changelog.md        | 4 ++++
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/libraries/base/GHC/IO/Exception.hs b/libraries/base/GHC/IO/Exception.hs
index 020bc067dfcf..cb53432d9e3e 100644
--- a/libraries/base/GHC/IO/Exception.hs
+++ b/libraries/base/GHC/IO/Exception.hs
@@ -269,12 +269,15 @@ instance Show ArrayException where
         . (if not (null s) then showString ": " . showString s
                            else id)
 
--- | @since TODO
+-- | The exception thrown when an infinite cycle is detected in 'fixIO'.
+--
+-- @since 4.11.0.0
 data FixIOException = FixIOException
 
--- | @since TODO
+-- | @since 4.11.0.0
 instance Exception FixIOException
 
+-- | @since 4.11.0.0
 instance Show FixIOException where
   showsPrec _ FixIOException = showString "cyclic evaluation in fixIO"
 
diff --git a/libraries/base/changelog.md b/libraries/base/changelog.md
index 39771170c781..cb9519c509d1 100644
--- a/libraries/base/changelog.md
+++ b/libraries/base/changelog.md
@@ -85,6 +85,10 @@
   * Deprecated STM invariant checking primitives (`checkInv`, `always`, and
     `alwaysSucceeds`) in `GHC.Conc.Sync` (#14324).
 
+  * Add a `FixIOException` data type to `Control.Exception.Base`, and change
+    `fixIO` to throw that instead of a `BlockedIndefinitelyOnMVar` exception
+    (#14356).
+
 ## 4.10.1.0 *November 2017*
   * Bundled with GHC 8.2.2
 
-- 
GitLab