From bf885d7a1a27e7b1cc34335a1e16d699fe084b47 Mon Sep 17 00:00:00 2001 From: Matthew Craven <5086-clyring@users.noreply.gitlab.haskell.org> Date: Tue, 8 Aug 2023 17:55:08 -0400 Subject: [PATCH] Bump bytestring submodule to 0.11.5, again Fixes #23789. The bytestring commit used here is unreleased; a release can be made when necessary. --- .gitlab-ci.yml | 2 +- compiler/GHC/Utils/Binary.hs | 4 ++-- hadrian/src/Settings/Warnings.hs | 2 ++ libraries/bytestring | 2 +- testsuite/tests/ghci/scripts/all.T | 8 ++++++-- 5 files changed, 12 insertions(+), 6 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6fd8e52d2e59..3c6c486c47ac 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -401,7 +401,7 @@ hadrian-multi: # workaround for docker permissions - sudo chown ghc:ghc -R . variables: - GHC_FLAGS: -Werror + GHC_FLAGS: "-Werror -Wwarn=deprecations" CONFIGURE_ARGS: --enable-bootstrap-with-devel-snapshot tags: - x86_64-linux diff --git a/compiler/GHC/Utils/Binary.hs b/compiler/GHC/Utils/Binary.hs index 2f569a105a88..03f13b1124dd 100644 --- a/compiler/GHC/Utils/Binary.hs +++ b/compiler/GHC/Utils/Binary.hs @@ -1240,13 +1240,13 @@ putBS :: BinHandle -> ByteString -> IO () putBS bh bs = BS.unsafeUseAsCStringLen bs $ \(ptr, l) -> do put_ bh l - putPrim bh l (\op -> BS.memcpy op (castPtr ptr) l) + putPrim bh l (\op -> copyBytes op (castPtr ptr) l) getBS :: BinHandle -> IO ByteString getBS bh = do l <- get bh :: IO Int BS.create l $ \dest -> do - getPrim bh l (\src -> BS.memcpy dest src l) + getPrim bh l (\src -> copyBytes dest src l) instance Binary ByteString where put_ bh f = putBS bh f diff --git a/hadrian/src/Settings/Warnings.hs b/hadrian/src/Settings/Warnings.hs index 1d87f2f91274..858f2a04952c 100644 --- a/hadrian/src/Settings/Warnings.hs +++ b/hadrian/src/Settings/Warnings.hs @@ -53,10 +53,12 @@ ghcWarningsArgs = do , package primitive ? pure [ "-Wno-unused-imports" , "-Wno-deprecations" ] , package rts ? pure [ "-Wcpp-undef" ] + , package text ? pure [ "-Wno-deprecations" ] , package terminfo ? pure [ "-Wno-unused-imports" ] , package transformers ? pure [ "-Wno-unused-matches" , "-Wno-unused-imports" , "-Wno-redundant-constraints" , "-Wno-orphans" ] + , package unix ? pure [ "-Wno-deprecations" ] , package win32 ? pure [ "-Wno-trustworthy-safe" ] , package xhtml ? pure [ "-Wno-unused-imports" ] ] ] diff --git a/libraries/bytestring b/libraries/bytestring index 9cab76dc861f..2bdeb7b0e7dd 160000 --- a/libraries/bytestring +++ b/libraries/bytestring @@ -1 +1 @@ -Subproject commit 9cab76dc861f651c3940e873ce921d9e09733cc8 +Subproject commit 2bdeb7b0e7dd100fce9e1f4d1ecf1cd6b5b9702c diff --git a/testsuite/tests/ghci/scripts/all.T b/testsuite/tests/ghci/scripts/all.T index 62d18f42ff9b..650472ce5c6b 100755 --- a/testsuite/tests/ghci/scripts/all.T +++ b/testsuite/tests/ghci/scripts/all.T @@ -57,7 +57,11 @@ test('ghci024', test('T9367', [req_interp, when(fast() or config.os != 'mingw32', skip)], makefile_test, []) -test('ghci025', extra_files(['Ghci025B.hs', 'Ghci025C.hs', 'Ghci025D.hs']), ghci_script, ['ghci025.script']) +test('ghci025', + [ extra_files(['Ghci025B.hs', 'Ghci025C.hs', 'Ghci025D.hs']), + normalise_version("bytestring")], + ghci_script, + ['ghci025.script']), test('ghci026', extra_files(['../prog002']), ghci_script, ['ghci026.script']) test('ghci027', [], ghci_script, ['ghci027.script']) @@ -216,7 +220,7 @@ test('T9762', , pre_cmd('$MAKE -s --no-print-directory T9762_prep') ], ghci_script, ['T9762.script']) -test('T9881', normal, ghci_script, ['T9881.script']) +test('T9881', normalise_version("bytestring"), ghci_script, ['T9881.script']) test('T9878', [], ghci_script, ['T9878.script']) test('T9878b', [extra_run_opts('-fobject-code')], ghci_script, ['T9878b.script']) -- GitLab