haskell / attoparsec

A fast Haskell library for parsing ByteStrings
http://hackage.haskell.org/package/attoparsec
Other
514 stars 93 forks source link

Fix memcpy/memset deprecation warning #221

Open topikettunen opened 1 year ago

topikettunen commented 1 year ago

Fix deprecation warnings mentioned in #220

Closes #220

topikettunen commented 1 year ago

@andreasabel, Seems that fillBytes was introduced in GHC 7.10.1 and base version 4.8.0.0. Are we still interested in supporting even older versions that failed the check? If so, I guess we could yank the fillBytes function from the newer versions and just wrap it in some preprocessor.

andreasabel commented 1 year ago

@topikettunen, thanks for investigating! There are basically 3 ways to proceed.

  1. Just leave the deprecation warnings in and worry about them once the functions get actually removed.
  2. Use base-compat to get fillBytes for older base: https://hackage.haskell.org/package/base-compat-0.13.0/docs/Foreign-Marshal-Utils-Compat.html#v:fillBytes
  3. Drop GHC < 7.10.

Maybe @bgamari should decide the course of action here.