On GHC 9.14.1, test-qc at 2fdb2a9786e4ec9c15185804d1378360f3fcd058 fails when built with -Werror:
test/Main.hs:14:14: error: [GHC-53692] [-Wdeprecated-flags, Werror=deprecated-flags]
-XTypeInType is deprecated: use -XDataKinds and -XPolyKinds instead
Replacing that pragma inside its existing CPP guard fixes the build:
#if __GLASGOW_HASKELL__ >= 805
{-# LANGUAGE DerivingVia #-}
-{-# LANGUAGE TypeInType #-}
+{-# LANGUAGE DataKinds #-}
+{-# LANGUAGE PolyKinds #-}
#endif
Before: test compilation fails. After: all 385 tests pass with -Werror, with no test cases removed and no additional warning suppression. Tested on Linux with Cabal 3.16.1.0 and this project configuration:
packages: .
with-compiler: ghc-9.14.1
index-state: 2026-09-12T04:56:46Z
optimization: 2
tests: True
benchmarks: False
constraints: base ==4.22.0.0, deepseq ==1.5.1.0,
transformers ==0.6.1.2, template-haskell ==2.24.0.0,
QuickCheck ==2.15.0.1
package primitive
ghc-options: -Werror -optl-fuse-ld=lld
Run cabal test primitive:test:test-qc --test-show-details=direct with LLVM lld installed. The comparison used separate build directories and an initially empty separate Cabal store. No allow-newer was needed. I have not tested the pragma change across the older supported GHC versions.
We found this while checking the dependencies of our TLS application under a warning-fatal build policy. The latest published Primitive 0.9.1.0 also fails that policy on three deprecated mutable-array size primops. I see #434 already handles those library warnings on master with module-level -Wno-deprecations; that is separate from this remaining test warning. A release containing that work and this test fix would help us validate the published package's own suite. Happy to contribute the test-source change and supply the captured logs/plans.
On GHC 9.14.1,
test-qcat2fdb2a9786e4ec9c15185804d1378360f3fcd058fails when built with-Werror:Replacing that pragma inside its existing CPP guard fixes the build:
#if __GLASGOW_HASKELL__ >= 805 {-# LANGUAGE DerivingVia #-} -{-# LANGUAGE TypeInType #-} +{-# LANGUAGE DataKinds #-} +{-# LANGUAGE PolyKinds #-} #endifBefore: test compilation fails. After: all 385 tests pass with
-Werror, with no test cases removed and no additional warning suppression. Tested on Linux with Cabal 3.16.1.0 and this project configuration:Run
cabal test primitive:test:test-qc --test-show-details=directwith LLVM lld installed. The comparison used separate build directories and an initially empty separate Cabal store. Noallow-newerwas needed. I have not tested the pragma change across the older supported GHC versions.We found this while checking the dependencies of our TLS application under a warning-fatal build policy. The latest published Primitive 0.9.1.0 also fails that policy on three deprecated mutable-array size primops. I see #434 already handles those library warnings on master with module-level
-Wno-deprecations; that is separate from this remaining test warning. A release containing that work and this test fix would help us validate the published package's own suite. Happy to contribute the test-source change and supply the captured logs/plans.