awakesecurity / proto3-wire

https://hackage.haskell.org/package/proto3-wire
Other
23 stars 30 forks source link

Allow bytestring-0.11 and ghc-prim-0.9 #80

Closed TristanCacqueray closed 2 years ago

TristanCacqueray commented 2 years ago

This change enables building with ghc-9.2 by fixing this error:

src/Proto3/Wire/Reverse/Prim.hs:829:54: error:
    Not in scope: data constructor ‘W32#’
    Perhaps you want to add ‘W32#’ to the import list in the import of
    ‘GHC.Word.Compat’
    (src/Proto3/Wire/Reverse/Prim.hs:(124,1)-(125,73)).
    |
829 |     shR s = case fromIntegral (shiftR (W64# x) s) of W32# y -> y
    |                                                      ^^^^

But adding the import does not seems to work, so this change replaces Data.Word with GHC.Word.Compat and removes the explicit import list.