diff --git a/.nix-helpers/nixpkgs.nix b/.nix-helpers/nixpkgs.nix
--- a/.nix-helpers/nixpkgs.nix
+++ b/.nix-helpers/nixpkgs.nix
@@ -26,13 +26,13 @@
     if isNull nixpkgs
       then
         builtins.fetchTarball {
-          # Recent version of nixpkgs master as of 2020-08-18 which uses LTS-16.9.
-          url = "https://github.com/NixOS/nixpkgs/archive/c5815280e92112a25d958a2ec8b3704d7d90c506.tar.gz";
-          sha256 = "09ic4s9s7w3lm0gmcxszm5j20cfv4n5lfvhdvgi7jzdbbbdps1nh";
+          # Recent version of nixpkgs master as of 2020-12-27 which uses nightly-2020-12-14.
+          url = "https://github.com/NixOS/nixpkgs/archive/84917aa00bf23c88e5874c683abe05edb0ba4078.tar.gz";
+          sha256 = "1x3qh815d7k9yc72zpn5cfaaq2b1942q4pka6rx8b5i33yz4m61q";
         }
       else nixpkgs;
 
-  compilerVersion = if isNull compiler then "ghc884" else compiler;
+  compilerVersion = if isNull compiler then "ghc8103" else compiler;
 
   # An overlay that adds termonad to all haskell package sets.
   haskellPackagesOverlay = self: super: {
@@ -66,7 +66,10 @@
                   src
                   extraCabal2nixOptions
                   {
-                    inherit (self) gtk3;
+                    # There are Haskell packages called gtk3 and pcre2, which
+                    # makes these system dependencies not able to be resolved
+                    # correctly.
+                    inherit (self) gtk3 pcre2;
                     vte_291 = self.vte;
                   };
             in
@@ -95,6 +98,7 @@
           self.cabal-install
           self.gnome3.glade
           self.haskellPackages.ghcid
+          self.hlint
         ];
       in
 
diff --git a/.nix-helpers/termonad-with-packages.nix b/.nix-helpers/termonad-with-packages.nix
--- a/.nix-helpers/termonad-with-packages.nix
+++ b/.nix-helpers/termonad-with-packages.nix
@@ -115,7 +115,7 @@
 in
 
 stdenv.mkDerivation {
-  name = "termonad-with-packages-${env.version}";
+  name = "termonad-with-packages-ghc-${env.version}";
   buildInputs = [ gdk_pixbuf gnome3.adwaita-icon-theme hicolor-icon-theme ];
   nativeBuildInputs = [ wrapGAppsHook ];
   dontBuild = true;
diff --git a/CHANGELOG.md b/CHANGELOG.md
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,9 @@
+## 4.0.1.2
+
+*   Disable doctest test-suite when building with GHC-8.10.3.  The doctests
+    appear to be segfaulting, but only when compiled with GHC-8.10.3.
+    [#175](https://github.com/cdepillabout/termonad/pull/175).
+
 ## 4.0.1.1
 
 *   Bump upper dependency on `base` so that Termonad is compatible with
diff --git a/Setup.hs b/Setup.hs
--- a/Setup.hs
+++ b/Setup.hs
@@ -102,7 +102,7 @@
   :: Version
   -> [String]
 createVteVersionCPPOpts vers =
-  catMaybes $
+  catMaybes
     [ if vers >= mkVersion [0,44] then Just "-DVTE_VERSION_GEQ_0_44" else Nothing
     ]
 
@@ -116,7 +116,7 @@
   :: Version  -- ^ 'Version' of the GTK3 library as reported by @pkg-config@.
   -> [String] -- ^ A list of CPP macros to show the GTK version.
 createGtkVersionCPPOpts gtkVersion =
-  catMaybes $
+  catMaybes
     [ if gtkVersion >= mkVersion [3,22] then Just "-DGTK_VERSION_GEQ_3_22" else Nothing
     ]
 
diff --git a/example-config/ExampleColourExtension.hs b/example-config/ExampleColourExtension.hs
--- a/example-config/ExampleColourExtension.hs
+++ b/example-config/ExampleColourExtension.hs
@@ -4,6 +4,8 @@
 
 module Main where
 
+import Data.Maybe (fromMaybe)
+
 import Termonad
   ( CursorBlinkMode(CursorBlinkModeOff), Option(Set)
   , ShowScrollbar(ShowScrollbarNever), TMConfig, confirmExit, cursorBlinkMode
@@ -44,7 +46,7 @@
     -- Set the extended palette that has 8 colours standard colors and then 8
     -- light colors.
     , palette = ExtendedPalette myStandardColours
-                                (maybe defaultLightColours id myLightColours)
+                                (fromMaybe defaultLightColours myLightColours)
     }
   where
     -- This is a an example of creating a linked-list of colours,
diff --git a/example-config/ExampleGruvboxColourExtension.hs b/example-config/ExampleGruvboxColourExtension.hs
--- a/example-config/ExampleGruvboxColourExtension.hs
+++ b/example-config/ExampleGruvboxColourExtension.hs
@@ -4,6 +4,7 @@
 
 module Main where
 
+import Data.Maybe (fromMaybe)
 import Termonad
   ( CursorBlinkMode(CursorBlinkModeOn)
   , Option(Set)
@@ -70,7 +71,7 @@
     }
   where
     gruvboxDark1 :: List8 (AlphaColour Double)
-    gruvboxDark1 = maybe defaultStandardColours id $ mkList8
+    gruvboxDark1 = fromMaybe defaultStandardColours $ mkList8
       [ createColour  40  40  40 -- bg0
       , createColour 204  36  29 -- red.1
       , createColour 152 151  26 -- green.2
@@ -82,7 +83,7 @@
       ]
 
     gruvboxDark2 :: List8 (AlphaColour Double)
-    gruvboxDark2 = maybe defaultStandardColours id $ mkList8
+    gruvboxDark2 = fromMaybe defaultStandardColours $ mkList8
       [ createColour 124 111 100 -- bg4
       , createColour 251  71  52 -- red.9
       , createColour 184 187  38 -- green.10
@@ -105,7 +106,7 @@
     }
   where
     gruvboxLight1 :: List8 (AlphaColour Double)
-    gruvboxLight1 = maybe defaultLightColours id $ mkList8
+    gruvboxLight1 = fromMaybe defaultLightColours $ mkList8
       [ createColour 251 241 199 -- bg0
       , createColour 204  36  29 -- red.1
       , createColour 152 151  26 -- green.2
@@ -117,7 +118,7 @@
       ]
 
     gruvboxLight2 :: List8 (AlphaColour Double)
-    gruvboxLight2 = maybe defaultLightColours id $ mkList8
+    gruvboxLight2 = fromMaybe defaultLightColours $ mkList8
       [ createColour 168 153 132 -- bg4
       , createColour 157   0   6 -- red.9
       , createColour 121 116  14 -- green.10
diff --git a/example-config/ExampleSolarizedColourExtension.hs b/example-config/ExampleSolarizedColourExtension.hs
--- a/example-config/ExampleSolarizedColourExtension.hs
+++ b/example-config/ExampleSolarizedColourExtension.hs
@@ -4,6 +4,7 @@
 
 module Main where
 
+import Data.Maybe (fromMaybe)
 import Termonad
   ( CursorBlinkMode(CursorBlinkModeOn)
   , Option(Set)
@@ -70,7 +71,7 @@
     }
   where
     solarizedDark1 :: List8 (AlphaColour Double)
-    solarizedDark1 = maybe defaultStandardColours id $ mkList8
+    solarizedDark1 = fromMaybe defaultStandardColours $ mkList8
       [ createColour   7  54  66 -- base02
       , createColour 220  50  47 -- red
       , createColour 133 153   0 -- green
@@ -82,7 +83,7 @@
       ]
 
     solarizedDark2 :: List8 (AlphaColour Double)
-    solarizedDark2 = maybe defaultStandardColours id $ mkList8
+    solarizedDark2 = fromMaybe defaultStandardColours $ mkList8
       [ createColour   0  43  54 -- base03
       , createColour 203  75  22 -- orange
       , createColour  88 110 117 -- base01
@@ -105,7 +106,7 @@
     }
   where
     solarizedLight1 :: List8 (AlphaColour Double)
-    solarizedLight1 = maybe defaultLightColours id $ mkList8
+    solarizedLight1 = fromMaybe defaultLightColours $ mkList8
       [ createColour   7  54  66 -- base02
       , createColour 220  50  47 -- red
       , createColour 133 153   0 -- green
@@ -117,7 +118,7 @@
       ]
 
     solarizedLight2 :: List8 (AlphaColour Double)
-    solarizedLight2 = maybe defaultLightColours id $ mkList8
+    solarizedLight2 = fromMaybe defaultLightColours $ mkList8
       [ createColour   0  43  54 -- base03
       , createColour 203  75  22 -- orange
       , createColour  88 110 117 -- base01
diff --git a/src/Termonad/App.hs b/src/Termonad/App.hs
--- a/src/Termonad/App.hs
+++ b/src/Termonad/App.hs
@@ -1,5 +1,3 @@
-{-# LANGUAGE ForeignFunctionInterface #-}
-
 module Termonad.App where
 
 import Termonad.Prelude
@@ -315,6 +313,7 @@
 --
 -- If 'confirmExit' is 'False', then this function always returns
 -- 'ResponseTypeYes'.
+{- HLINT ignore "Reduce duplication" -}
 askShouldExit :: TMState -> IO ResponseType
 askShouldExit mvarTMState = do
   tmState <- readMVar mvarTMState
@@ -691,9 +690,9 @@
   tmState <- readMVar mvarTMState
   let appWin = tmState ^. lensTMStateAppWin
       config = tmState ^. lensTMStateConfig
-      notebook = tmState ^. lensTMStateNotebook ^. lensTMNotebook
-      tabFocusList = tmState ^. lensTMStateNotebook ^. lensTMNotebookTabs
-      showMenu = config  ^. lensOptions ^. lensShowMenu
+      notebook = tmState ^. lensTMStateNotebook . lensTMNotebook
+      tabFocusList = tmState ^. lensTMStateNotebook . lensTMNotebookTabs
+      showMenu = config  ^. lensOptions . lensShowMenu
   applicationWindowSetShowMenubar appWin showMenu
   setShowTabs config notebook
   -- Sets the remaining preferences to each tab
@@ -703,9 +702,9 @@
 applyNewPreferencesToTab mvarTMState tab = do
   tmState <- readMVar mvarTMState
   let fontDesc = tmState ^. lensTMStateFontDesc
-      term = tab ^. lensTMNotebookTabTerm ^. lensTerm
+      term = tab ^. lensTMNotebookTabTerm . lensTerm
       scrolledWin = tab ^. lensTMNotebookTabTermContainer
-      options = tmState ^. lensTMStateConfig ^. lensOptions
+      options = tmState ^. lensTMStateConfig . lensOptions
   terminalSetFont term (Just fontDesc)
   terminalSetCursorBlinkMode term (options ^. lensCursorBlinkMode)
   terminalSetWordCharExceptions term (options ^. lensWordCharExceptions)
@@ -799,7 +798,7 @@
   when (toEnum (fromIntegral res) == ResponseTypeAccept) $ do
     maybeFontDesc <- fontChooserGetFontDesc fontButton
     maybeFontConfig <-
-      liftM join $ mapM fontConfigFromFontDescription maybeFontDesc
+      join <$> mapM fontConfigFromFontDescription maybeFontDesc
     maybeShowScrollbar <-
       comboBoxGetActive showScrollbarComboBoxText [ShowScrollbarNever ..]
     maybeShowTabBar <-
@@ -923,7 +922,7 @@
             "configuration file and running termonad with default settings."
           start tmConfig
       | otherwise -> do
-          putStrLn $ "IO error occurred when trying to run termonad:"
+          putStrLn "IO error occurred when trying to run termonad:"
           print ioErr
           putStrLn "Don't know how to recover.  Exiting."
     Right _ -> pure ()
diff --git a/src/Termonad/Config/Colour.hs b/src/Termonad/Config/Colour.hs
--- a/src/Termonad/Config/Colour.hs
+++ b/src/Termonad/Config/Colour.hs
@@ -177,7 +177,7 @@
 -- >>> setAt 100 "hello" ["a","b","c","d"]
 -- ["a","b","c","d"]
 setAt :: forall a. Int -> a -> [a] -> [a]
-setAt n newVal = overAt n (\_ -> newVal)
+setAt n newVal = overAt n (const newVal)
 
 -- | Update a given value in a list.
 --
@@ -280,14 +280,14 @@
   deriving (Show, Eq, Functor, Foldable)
 
 getMatrix :: Matrix a -> [[[a]]]
-getMatrix (Matrix (List6 m)) = fmap getList6 $ (fmap . fmap) getList6 m
+getMatrix (Matrix (List6 m)) = fmap (getList6 . fmap getList6) m
 
 -- | Unsafe smart constructor for 6x6x6 Matrices.
 mkMatrix :: [[[a]]] -> Maybe (Matrix a)
 mkMatrix xs =
   if length xs == 6 && all (\x -> length x == 6) xs
                     && all (all (\x -> length x == 6)) xs
-  then Just $ Matrix $ List6 (fmap List6 ((fmap . fmap) List6 xs))
+  then Just $ Matrix $ List6 (fmap (List6 . fmap List6) xs)
   else Nothing
 
 -- | Unsafe smart constructor for 6x6x6 Matrices.
@@ -296,14 +296,14 @@
   case mkMatrix xs of
     Just xs' -> xs'
     Nothing ->
-      error $
+      error
         "unsafeMkMatrix: input list must be exactly 6x6x6"
 
 -- | Set a given value in a 'Matrix'.
 --
 -- Internally uses 'setAt'.  See documentation on 'setAt' for some examples.
 setAtMatrix :: Int -> Int -> Int -> a -> Matrix a -> Matrix a
-setAtMatrix x y z a m = overAtMatrix x y z (\_ -> a) m
+setAtMatrix x y z a = overAtMatrix x y z (const a)
 
 -- | Set a given value in a 'Matrix'.
 --
@@ -496,7 +496,7 @@
 sRGB32 r g b 255 = withOpacity (sRGB24 r g b) 1
 sRGB32 r g b a =
   let aDouble = fromIntegral a / 255
-  in (withOpacity (sRGB24 r g b) aDouble)
+  in withOpacity (sRGB24 r g b) aDouble
 
 -- | Create an 'AlphaColour' that is fully 'opaque'.
 --
@@ -873,4 +873,3 @@
 addColourHook newHook oldHook tmState term = do
   oldHook tmState term
   newHook tmState term
-
diff --git a/src/Termonad/Term.hs b/src/Termonad/Term.hs
--- a/src/Termonad/Term.hs
+++ b/src/Termonad/Term.hs
@@ -362,7 +362,7 @@
   -- Should probably use GI.Vte.Functions.getUserShell, but contrary to its
   -- documentation it raises an exception rather wrap in Maybe.
   mShell <- lookupEnv "SHELL"
-  let argv = fromMaybe ["/usr/bin/env", "bash"] (pure <$> mShell)
+  let argv = maybe ["/usr/bin/env", "bash"] pure mShell
   -- Launch the shell
   shellPid <-
     terminalSpawnSync
@@ -484,4 +484,3 @@
     menuAttachToWidget menu vteTerm Nothing
     menuPopupAtPointer menu Nothing
   pure rightClick
-
diff --git a/src/Termonad/Types.hs b/src/Termonad/Types.hs
--- a/src/Termonad/Types.hs
+++ b/src/Termonad/Types.hs
@@ -155,9 +155,7 @@
     }
 
 newTMTerm :: Terminal -> Int -> IO TMTerm
-newTMTerm trm pd = do
-  unq <- newUnique
-  pure $ createTMTerm trm pd unq
+newTMTerm trm pd = createTMTerm trm pd <$> newUnique
 
 getFocusedTermFromState :: TMState -> IO (Maybe Terminal)
 getFocusedTermFromState mvarTMState =
@@ -342,7 +340,7 @@
 -- []
 whenSet :: Monoid m => Option a -> (a -> m) -> m
 whenSet = \case
-  Unset -> \_ -> mempty
+  Unset -> const mempty
   Set x -> \f -> f x
 
 -- | Whether or not to show the scroll bar in a terminal.
@@ -464,7 +462,7 @@
 -- termonad's behaviour in order to implement new functionality. Fields should
 -- have sane @Semigroup@ and @Monoid@ instances so that config extensions can
 -- be combined uniformly and new hooks can be added without incident.
-data ConfigHooks = ConfigHooks {
+newtype ConfigHooks = ConfigHooks {
   -- | Produce an IO action to run on creation of new @Terminal@, given @TMState@
   -- and the @Terminal@ in question.
   createTermHook :: TMState -> Terminal -> IO ()
@@ -535,7 +533,7 @@
       maybeWidgetFromNote <- notebookGetNthPage tmNote index32
       let focusList = tmNotebookTabs $ tmStateNotebook tmState
           maybeScrollWinFromFL =
-            fmap tmNotebookTabTermContainer $ getFocusItemFL $ focusList
+            tmNotebookTabTermContainer <$> getFocusItemFL focusList
           idx = fromIntegral index32
       case (maybeWidgetFromNote, maybeScrollWinFromFL) of
         (Nothing, Nothing) -> pure Nothing
@@ -575,7 +573,7 @@
     invariantTabsAllMatch = do
       let tmNote = tmNotebook $ tmStateNotebook tmState
           focusList = tmNotebookTabs $ tmStateNotebook tmState
-          flList = fmap tmNotebookTabTermContainer $ toList focusList
+          flList = tmNotebookTabTermContainer <$> toList focusList
       noteList <- notebookToList tmNote
       tabsMatch noteList flList
       where
diff --git a/termonad.cabal b/termonad.cabal
--- a/termonad.cabal
+++ b/termonad.cabal
@@ -1,5 +1,5 @@
 name:                termonad
-version:             4.0.1.1
+version:             4.0.1.2
 synopsis:            Terminal emulator configurable in Haskell
 description:
   Termonad is a terminal emulator configurable in Haskell.  It is extremely
@@ -147,8 +147,15 @@
                      , doctest
                      , QuickCheck
                      , template-haskell
+                     , termonad
   default-language:    Haskell2010
   ghc-options:         -Wall -threaded -rtsopts -with-rtsopts=-N
+  -- For some reason doctests appear to be segfaulting when compiling with
+  -- ghc-8.10.3, so only build them when using ghc-8.10.2 or earlier.
+  if impl(ghc <= 8.10.2)
+    buildable:         True
+  else
+    buildable:         False
 
 test-suite termonad-test
   type:                exitcode-stdio-1.0
