Skip to content

This package does not build with GHC 9.4.8. #6

Description

@kindaro

what I do

% git remote -v
origin	https://github.com/pxqr/base32-bytestring.git (fetch)
origin	https://github.com/pxqr/base32-bytestring.git (push)
% git rev-parse @
3a6fe39aa734fd053baababdc8afa413999c8cd1
% ghc --version
The Glorious Glasgow Haskell Compilation System, version 9.4.8
% cabal build
Build profile: -w ghc-9.4.8 -O1
In order, the following will be built (use -v for more details):
 - base32-bytestring-0.2.1.0 (lib) (first run)
Preprocessing library for base32-bytestring-0.2.1.0..
Building library for base32-bytestring-0.2.1.0..
[1 of 3] Compiling Data.ByteString.Base32.Internal ( src/Data/ByteString/Base32/Internal.hs, /tmp/base32-bytestring/dist-newstyle/build/x86_64-linux/ghc-9.4.8/base32-bytestring-0.2.1.0/build/Data/ByteString/Base32/Internal.o, /tmp/base32-bytestring/dist-newstyle/build/x86_64-linux/ghc-9.4.8/base32-bytestring-0.2.1.0/build/Data/ByteString/Base32/Internal.dyn_o )

src/Data/ByteString/Base32/Internal.hs:73:1: error:
    Parse error in pattern: unpack5Ptr In a function binding for the ‘@’ operator.
                            Perhaps you meant an as-pattern, which must not be surrounded by whitespace
   |
73 | unpack5Ptr !tbl bs @ (PS fptr off sz) =
   | ^^^^^^^^^^^^^^^^^^
Error: cabal: Failed to build base32-bytestring-0.2.1.0.

what should happen

Running cabal build should build the package.

discussion

The reason for this error is that the parsing of @ has become white space sensitive, I think since the proposal ghc-proposals/ghc-proposals#229, so in this case white space about the @ needs to be cut away.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions