diff --git a/CHANGELOG.md b/CHANGELOG.md
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,6 @@
+### 0.6.6 [2024.03.19]
+* Support building with `template-haskell-2.22.*` (GHC 9.10).
+
 ### 0.6.5 [2023.08.06]
 * When generating `Show(1)(2)` instances with `Text.Show.Deriving` using GHC 9.8
   or later, data types that have fields of type `Int{8,16,32,64}#` or
diff --git a/deriving-compat.cabal b/deriving-compat.cabal
--- a/deriving-compat.cabal
+++ b/deriving-compat.cabal
@@ -1,5 +1,5 @@
 name:                deriving-compat
-version:             0.6.5
+version:             0.6.6
 synopsis:            Backports of GHC deriving extensions
 description:         @deriving-compat@ provides Template Haskell functions that
                      mimic @deriving@ extensions that were introduced or modified
@@ -92,8 +92,10 @@
                    , GHC == 8.10.7
                    , GHC == 9.0.2
                    , GHC == 9.2.8
-                   , GHC == 9.4.5
-                   , GHC == 9.6.2
+                   , GHC == 9.4.8
+                   , GHC == 9.6.4
+                   , GHC == 9.8.2
+                   , GHC == 9.10.1
 cabal-version:       >=1.10
 
 source-repository head
@@ -139,9 +141,9 @@
                        Text.Read.Deriving.Internal
                        Text.Show.Deriving
                        Text.Show.Deriving.Internal
-  build-depends:       containers          >= 0.1   && < 0.7
+  build-depends:       containers          >= 0.1   && < 0.8
                      , ghc-prim
-                     , th-abstraction      >= 0.4   && < 0.7
+                     , th-abstraction      >= 0.4   && < 0.8
 
   if flag(base-4-9)
     build-depends:     base                >= 4.9   && < 5
@@ -151,7 +153,7 @@
                      , semigroups          >= 0.6   && < 0.21
 
   if flag(template-haskell-2-11)
-    build-depends:     template-haskell    >= 2.11  && < 2.22
+    build-depends:     template-haskell    >= 2.11  && < 2.23
                      , ghc-boot-th
   else
     build-depends:     template-haskell    >= 2.5   && < 2.11
@@ -190,7 +192,7 @@
                      , hspec               >= 1.8
                      , QuickCheck          >= 2      && < 3
                      , tagged              >= 0.7    && < 1
-                     , template-haskell    >= 2.5    && < 2.22
+                     , template-haskell    >= 2.5    && < 2.23
                      , void                >= 0.5.10 && < 1
   build-tool-depends:  hspec-discover:hspec-discover >= 1.8
 
diff --git a/src/Data/Functor/Deriving/Internal.hs b/src/Data/Functor/Deriving/Internal.hs
--- a/src/Data/Functor/Deriving/Internal.hs
+++ b/src/Data/Functor/Deriving/Internal.hs
@@ -837,16 +837,14 @@
 mkSimpleLam :: (Exp -> Q Exp) -> Q Exp
 mkSimpleLam lam = do
   n <- newName "n"
-  body <- lam (VarE n)
-  return $ LamE [VarP n] body
+  lamE [varP n] $ lam (VarE n)
 
 -- Make a 'LamE' using two fresh variables.
 mkSimpleLam2 :: (Exp -> Exp -> Q Exp) -> Q Exp
 mkSimpleLam2 lam = do
   n1 <- newName "n1"
   n2 <- newName "n2"
-  body <- lam (VarE n1) (VarE n2)
-  return $ LamE [VarP n1, VarP n2] body
+  lamE [varP n1, varP n2] $ lam (VarE n1) (VarE n2)
 
 -- "Con a1 a2 a3 -> fold [x1 a1, x2 a2, x3 a3]"
 --
