diff --git a/Cabal-syntax/src/Language/Haskell/Extension.hs b/Cabal-syntax/src/Language/Haskell/Extension.hs index 2d092cd92465c32b5db5e4625c6157c3c186df00..7cc4ebc18d654183fd9dfa55828a8849d97ab9fe 100644 --- a/Cabal-syntax/src/Language/Haskell/Extension.hs +++ b/Cabal-syntax/src/Language/Haskell/Extension.hs @@ -861,9 +861,23 @@ data KnownExtension = -- | Enable the use of record dot-accessor and updater syntax | OverloadedRecordDot + -- | Provides record @.@ syntax in record updates, e.g. @x {foo.bar = 1}@. + -- + -- * <https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/exts/overloaded_record_update.html#extension-OverloadedRecordUpdate> + | OverloadedRecordUpdate + -- | Enable data types for which an unlifted or levity-polymorphic result kind is inferred. | UnliftedDatatypes + -- | Undocumented parsing-related extensions introduced in GHC 7.0. + | AlternativeLayoutRule + + -- | Undocumented parsing-related extensions introduced in GHC 7.0. + | AlternativeLayoutRuleTransitional + + -- | Undocumented parsing-related extensions introduced in GHC 7.2. + | RelaxedLayout + deriving (Generic, Show, Read, Eq, Ord, Enum, Bounded, Typeable, Data) instance Binary KnownExtension diff --git a/Cabal-tests/tests/UnitTests/Distribution/Utils/Structured.hs b/Cabal-tests/tests/UnitTests/Distribution/Utils/Structured.hs index b2c6e32cadebbe2212d3e098dd7ff5c64f429f11..56be131a9f19810fb02e1b5d886027867112a053 100644 --- a/Cabal-tests/tests/UnitTests/Distribution/Utils/Structured.hs +++ b/Cabal-tests/tests/UnitTests/Distribution/Utils/Structured.hs @@ -27,9 +27,9 @@ tests = testGroup "Distribution.Utils.Structured" -- The difference is in encoding of newtypes #if MIN_VERSION_base(4,7,0) , testCase "GenericPackageDescription" $ - md5Check (Proxy :: Proxy GenericPackageDescription) 0x344677c9c09bde1c0f8cf94dc2b45030 + md5Check (Proxy :: Proxy GenericPackageDescription) 0xaf3d4c667a8f019c98a45451419ad71c , testCase "LocalBuildInfo" $ - md5Check (Proxy :: Proxy LocalBuildInfo) 0x637b149bf956b706bfd3e4f99e66a910 + md5Check (Proxy :: Proxy LocalBuildInfo) 0x6d132d3f99c869b678468256f24b6241 #endif ] diff --git a/changelog.d/pr-8170 b/changelog.d/pr-8170 new file mode 100644 index 0000000000000000000000000000000000000000..3a71e36c276e33821b9f06a4d1bef8f5ae1aad50 --- /dev/null +++ b/changelog.d/pr-8170 @@ -0,0 +1,11 @@ +synopsis: Update the list of known GHC extensions to match GHC 9.2 +packages: Cabal-syntax +prs: #8170 +issues: #8168 + +description: { + +- Add OverloadedRecordUpdate and undocumented AlternativeLayoutRule, + AlternativeLayoutRuleTransitional, RelaxedLayout to KnownExtension. + +}